Cloud-oriented Life

Cloud Native Technology Improves Lives

Summary - Building software with David Heinemeier Hansson

This article is about Building software with David Heinemeier Hansson from Computers Are Hard: building software with David Heinemeier Hansson | by Wojtek Borowicz | Computers Are Hard | Medium - https://medium.com/computers-are-hard/computers-are-hard-building-software-with-david-heinemeier-hansson-c9025cdf225e.

Read more »

helm-AppsCode-kubed-example

AppsCode Kubed

Kubed by AppsCode is a Kubernetes cluster manager daemon that can sync ConfigMaps/Secrets across Kubernetes namespaces or Clusters.

This article is about how to use Helm to install kubed on Kubernetes (K8S).

Read more »

kube-prometheus stack

Installs the kube-prometheus stack, a collection of Kubernetes manifests, Grafana dashboards, and Prometheus rules combined with documentation and scripts to provide easy to operate end-to-end Kubernetes cluster monitoring with Prometheus using the Prometheus Operator.

This article is about how to use Helm to deploy kube-prometheus stack (Prometheus, Grafana) on Kubernetes (K8S).

Read more »

MicroK8s

MicroK8s is the smallest, fastest, fully-conformant Kubernetes that tracks upstream releases and makes clustering trivial. MicroK8s is great for offline development, prototyping, and testing. Use it on a VM as a small, cheap, reliable k8s for CI/CD. It’s also the best production grade Kubernetes for appliances. Develop IoT apps for k8s and deploy them to MicroK8s on your Linux boxes.

Read more »

hexo-generator-searchdb

Hexo is a fast, simple & powerful blog framework. It use plugins to provide features powerful APIs for limitless extensibility. Various plugins are available to support most template engines (EJS, Pug, Nunjucks, and many others). Easily integrate with existing NPM packages (Babel, PostCSS, Less/Sass, etc).

hexo-generator-searchdb is used for generating a search index file, which contains all the necessary data of your articles that you can use to write a local search engine for your blog. Supports both XML and JSON format output.

Installation

Use npm to install hexo-generator-searchdb package.

1
2
3
$ npm install hexo-generator-searchdb

$ hexo clean

Configuration

First, configure this plugin in your Hexo root _config.yml. All the arguments are optional.

1
2
3
4
5
6
7
# _config.yml

search:
path: search.xml
field: post
content: true
format: html

The follow is the options:

  • path - file path. By default is search.xml. If the file extension is .json, the output format will be JSON. Otherwise XML format file will be exported.

  • field - the search scope you want to search, you can chose:

    • post (Default) - will only cover all the posts of your blog.

    • page - will only cover all the pages of your blog.

    • all - will cover all the posts and pages of your blog.

  • content - whether contains the whole content of each article. If false, the generated results only cover title and other meta info without mainbody. By default is true.

  • format - the form of the page contents, options are:

    • html (Default) - original html string being minified.

    • striptags - original html string being minified, and remove all the tags.

    • raw - markdown text of each posts or pages.

Then, configure this plugin in your hexo-theme-next plugin _config_next.yml.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
# _config_next.yml

# Local Search
# Dependencies: https://github.com/next-theme/hexo-generator-searchdb
local_search:
# DoItYourself
# enable: false
enable: true
# If auto, trigger search by changing input.
# If manual, trigger search by pressing enter key or search button.
trigger: auto
# Show top n results per article, show all results by setting to -1
top_n_per_article: 1
# Unescape html strings to the readable one.
unescape: false
# Preload the search data when the page loads.
preload: false

Finally, you can visit your site in the browser, and check whether the site works correctly after Hexo restarted or regenerated.

References

[1] hexojs/hexo-generator-searchdb: Add nofollow attribute to all external links automatically. - https://github.com/hexojs/hexo-generator-searchdb/

[2] Local Search - 第三方服务集成 - NexT 使用文档 - https://theme-next.iissnan.com/third-party-services.html#local-search

[3] Hexo - https://hexo.io/

[4] next-theme/awesome-next: 😎 Theme NexT, AWESOME NexT! - https://github.com/next-theme/awesome-next

Download or preview PDF files

Hexo is a fast, simple & powerful blog framework. It use plugins to provide features powerful APIs for limitless extensibility. Various plugins are available to support most template engines (EJS, Pug, Nunjucks, and many others). Easily integrate with existing NPM packages (Babel, PostCSS, Less/Sass, etc).

This article is about how to download or preview PDF files in Hexo.

PDF Folders

Global PDF Folder

Hexo Assets are non-post files in the source folder, such as images, CSS or JavaScript files. For instance, If you are only going to have a few PDF files in the Hexo project, then the easiest way is to keep them in a source/pdfs directory. Then, you can preview(by Browser preview) or download them using something like

1
[pdf demo](/pdfs/pdf-demo.pdf).

Post PDF Folder

For users who expect to regularly serve PDF files, and for those who prefer to separate their PDF files on a post-per-post basis, Hexo also provides a more organized way to manage assets. This slightly more involved, but very convenient approach to asset management can be turned on by setting the post_asset_folder setting in _config.yml to true.

1
2
3
4
5
# _config.yml

# DoItYourself
# post_asset_folder: false
post_asset_folder: true

With asset folder management enabled, Hexo will create a folder every time you make a new post with the hexo new [layout] command. This asset folder will have the same name as the markdown file associated with the post. Place all PDF files related to your post into the associated folder, and you will be able to reference them using a relative path, making for an easier and more convenient workflow.</p> <p>For example,</p> <figure class="highlight markdown"><table><tr><td class="gutter"><pre><span class="line">1</span><br></pre></td><td class="code"><pre><span class="line">[<span class="string">pdf demo</span>](<span class="link">pdf-demo.pdf</span>).</span><br></pre></td></tr></table></figure> <p>or</p> <figure class="highlight markdown"><table><tr><td class="gutter"><pre><span class="line">1</span><br></pre></td><td class="code"><pre><span class="line">[<span class="string">pdf demo</span>](<span class="link">./pdfs/pdf-demo.pdf</span>).</span><br></pre></td></tr></table></figure> <h2 id="Preview-PDF-Embed">Preview PDF Embed</h2> <p><code>theme-next-pdf</code> is a plugin that allows to preview PDF files embed in the blog pages.</p> <h3 id="Installation">Installation</h3> <p>Install module to source/lib directory.</p> <p>Ihis installation is optional if youe just want to preview external PDF files.</p> <figure class="highlight shell"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br></pre></td><td class="code"><pre><span class="line"><span class="meta prompt_"># </span><span class="language-bash">Use git submodule add</span></span><br><span class="line"><span class="meta prompt_">$ </span><span class="language-bash">git submodule add https://github.com/next-theme/theme-next-pdf <span class="built_in">source</span>/lib/pdf</span></span><br><span class="line"><span class="meta prompt_"></span></span><br><span class="line"><span class="meta prompt_"># </span><span class="language-bash">Or just use git <span class="built_in">clone</span></span></span><br><span class="line"><span class="meta prompt_">$ </span><span class="language-bash">git <span class="built_in">clone</span> https://github.com/next-theme/theme-next-pdf <span class="built_in">source</span>/lib/pdf</span></span><br><span class="line"><span class="meta prompt_"></span></span><br><span class="line"><span class="meta prompt_">$ </span><span class="language-bash">hexo clean</span></span><br></pre></td></tr></table></figure> <h3 id="Configuration">Configuration</h3> <p>Enable module in NexT <a href="./_config_next.yml">./_config_next.yml</a> file:</p> <figure class="highlight yaml"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br><span class="line">8</span><br><span class="line">9</span><br><span class="line">10</span><br><span class="line">11</span><br><span class="line">12</span><br></pre></td><td class="code"><pre><span class="line"><span class="comment"># _config_next.yml</span></span><br><span class="line"></span><br><span class="line"><span class="comment"># PDF tag</span></span><br><span class="line"><span class="comment"># NexT will try to load pdf files natively, if failed, pdf.js will be used.</span></span><br><span class="line"><span class="comment"># So, you have to install the dependency of pdf.js if you want to use pdf tag and make it available to all browsers.</span></span><br><span class="line"><span class="comment"># Dependencies: https://github.com/next-theme/theme-next-pdf</span></span><br><span class="line"><span class="attr">pdf:</span></span><br><span class="line"> <span class="comment"># DoItYourself</span></span><br><span class="line"> <span class="comment"># enable: false</span></span><br><span class="line"> <span class="attr">enable:</span> <span class="literal">true</span></span><br><span class="line"> <span class="comment"># Default height</span></span><br><span class="line"> <span class="attr">height:</span> <span class="string">500px</span></span><br></pre></td></tr></table></figure> <h3 id="Usage">Usage</h3> <p>In order to embed PDF files in the article, you just need to create an <code>pdf</code> tag with the URL of your local PDF file, e.g.</p> <ul> <li> <p>Local PDF files</p> <p>Remember to put <code>file.pdf</code> into the <code>source/path/to/your/file.pdf</code>, such as <code>source/pdfs/file.pdf</code>.</p> <figure class="highlight markdown"><table><tr><td class="gutter"><pre><span class="line">1</span><br></pre></td><td class="code"><pre><span class="line">{% pdf /path/to/your/file.pdf %}</span><br></pre></td></tr></table></figure> </li> <li> <p>External PDF files:</p> <figure class="highlight markdown"><table><tr><td class="gutter"><pre><span class="line">1</span><br></pre></td><td class="code"><pre><span class="line">{% pdf http://www.africau.edu/images/default/sample.pd %}</span><br></pre></td></tr></table></figure> </li> </ul> <hr> <p>Notice: Do not use cross-origin PDF files, it might be blocked by the CORS policy, unless you have resoved it.</p> <hr> <p>Enjoy it!</p> <h2 id="References">References</h2> <p>[1] <a target="_blank" rel="noopener external nofollow noreferrer" href="https://github.com/next-theme/theme-next-pdf">next-theme/theme-next-pdf: PDF.js for NexT. - https://github.com/next-theme/theme-next-pdf</a></p> <p>[2] <a target="_blank" rel="noopener external nofollow noreferrer" href="https://hexo.io/docs/tag-plugins">Tag Plugins | Hexo - https://hexo.io/docs/tag-plugins</a></p> <p>[3] <a target="_blank" rel="noopener external nofollow noreferrer" href="https://hexo.io/docs/asset-folders.html">Asset Folders | Hexo - https://hexo.io/docs/asset-folders.html</a></p> </div> <footer class="post-footer"> <div class="post-eof"></div> </footer> </article> </div> <div class="post-block"> <article itemscope itemtype="http://schema.org/Article" class="post-content" lang=""> <link itemprop="mainEntityOfPage" href="https://cloudolife.com/2020/10/24/Site/Hexo/Use-Docker-or-Docker-Compose-to-run-Hexo/"> <span hidden itemprop="author" itemscope itemtype="http://schema.org/Person"> <meta itemprop="image" content="/images/avatar.gif"> <meta itemprop="name" content="CloudoLife"> </span> <span hidden itemprop="publisher" itemscope itemtype="http://schema.org/Organization"> <meta itemprop="name" content="Cloud-oriented Life"> <meta itemprop="description" content="A Husband and Father, Knowledge Worker, Full-skilled Cloud Engineer"> </span> <span hidden itemprop="post" itemscope itemtype="http://schema.org/CreativeWork"> <meta itemprop="name" content="undefined | Cloud-oriented Life"> <meta itemprop="description" content=""> </span> <header class="post-header"> <h2 class="post-title" itemprop="name headline"> <a href="/2020/10/24/Site/Hexo/Use-Docker-or-Docker-Compose-to-run-Hexo/" class="post-title-link" itemprop="url">[Hexo] Use Docker or Docker Compose to run Hexo</a> </h2> <div class="post-meta-container"> <div class="post-meta"> <span class="post-meta-item"> <span class="post-meta-item-icon"> <i class="far fa-calendar"></i> </span> <span class="post-meta-item-text">Posted on</span> <time title="Created: 2020-10-24 00:00:00" itemprop="dateCreated datePublished" datetime="2020-10-24T00:00:00+00:00">2020-10-24</time> </span> <span class="post-meta-item"> <span class="post-meta-item-icon"> <i class="far fa-calendar-check"></i> </span> <span class="post-meta-item-text">Edited on</span> <time title="Modified: 2024-09-12 09:35:58" itemprop="dateModified" datetime="2024-09-12T09:35:58+00:00">2024-09-12</time> </span> <span class="post-meta-item"> <span class="post-meta-item-icon"> <i class="far fa-folder"></i> </span> <span class="post-meta-item-text">In</span> <span itemprop="about" itemscope itemtype="http://schema.org/Thing"> <a href="/categories/Site/" itemprop="url" rel="index"><span itemprop="name">Site</span></a> </span> , <span itemprop="about" itemscope itemtype="http://schema.org/Thing"> <a href="/categories/Site/Hexo/" itemprop="url" rel="index"><span itemprop="name">Hexo</span></a> </span> </span> <span class="post-meta-break"></span> <span class="post-meta-item" title="Word count in article"> <span class="post-meta-item-icon"> <i class="far fa-file-word"></i> </span> <span class="post-meta-item-text">Word count in article: </span> <span>2.4k</span> </span> <span class="post-meta-item" title="Reading time"> <span class="post-meta-item-icon"> <i class="far fa-clock"></i> </span> <span class="post-meta-item-text">Reading time ≈</span> <span>2 mins.</span> </span> </div> </div> </header> <div class="post-body" itemprop="articleBody"> <h1>col-hexo-docker</h1> <p><a target="_blank" rel="noopener external nofollow noreferrer" href="https://github.com/CloudoLife/col-hexo-docker">col-hexo</a> is a Docker image to use Docker or Docker Compose to run Hexo.</p> <p>Hexo is a fast, simple & powerful blog framework. It use plugins to provide features powerful APIs for limitless extensibility. Various plugins are available to support most template engines (EJS, Pug, Nunjucks, and many others). Easily integrate with existing NPM packages (Babel, PostCSS, Less/Sass, etc).</p> <!--noindex--> <div class="post-button"> <a class="btn" href="/2020/10/24/Site/Hexo/Use-Docker-or-Docker-Compose-to-run-Hexo/#more" rel="contents"> Read more » </a> </div> <!--/noindex--> </div> <footer class="post-footer"> <div class="post-eof"></div> </footer> </article> </div> <div class="post-block"> <article itemscope itemtype="http://schema.org/Article" class="post-content" lang=""> <link itemprop="mainEntityOfPage" href="https://cloudolife.com/2020/10/24/Site/Hexo/Use-hexo-related-popular-posts-plugin-to-generates-a-list-of-links-to-related-posts-or-popular-posts-in-Hexo/"> <span hidden itemprop="author" itemscope itemtype="http://schema.org/Person"> <meta itemprop="image" content="/images/avatar.gif"> <meta itemprop="name" content="CloudoLife"> </span> <span hidden itemprop="publisher" itemscope itemtype="http://schema.org/Organization"> <meta itemprop="name" content="Cloud-oriented Life"> <meta itemprop="description" content="A Husband and Father, Knowledge Worker, Full-skilled Cloud Engineer"> </span> <span hidden itemprop="post" itemscope itemtype="http://schema.org/CreativeWork"> <meta itemprop="name" content="undefined | Cloud-oriented Life"> <meta itemprop="description" content=""> </span> <header class="post-header"> <h2 class="post-title" itemprop="name headline"> <a href="/2020/10/24/Site/Hexo/Use-hexo-related-popular-posts-plugin-to-generates-a-list-of-links-to-related-posts-or-popular-posts-in-Hexo/" class="post-title-link" itemprop="url">[Hexo] Use hexo-related-popular-posts plugin to generates a list of links to related posts or popular posts in Hexo</a> </h2> <div class="post-meta-container"> <div class="post-meta"> <span class="post-meta-item"> <span class="post-meta-item-icon"> <i class="far fa-calendar"></i> </span> <span class="post-meta-item-text">Posted on</span> <time title="Created: 2020-10-24 00:00:00" itemprop="dateCreated datePublished" datetime="2020-10-24T00:00:00+00:00">2020-10-24</time> </span> <span class="post-meta-item"> <span class="post-meta-item-icon"> <i class="far fa-calendar-check"></i> </span> <span class="post-meta-item-text">Edited on</span> <time title="Modified: 2024-09-12 09:35:58" itemprop="dateModified" datetime="2024-09-12T09:35:58+00:00">2024-09-12</time> </span> <span class="post-meta-item"> <span class="post-meta-item-icon"> <i class="far fa-folder"></i> </span> <span class="post-meta-item-text">In</span> <span itemprop="about" itemscope itemtype="http://schema.org/Thing"> <a href="/categories/Site/" itemprop="url" rel="index"><span itemprop="name">Site</span></a> </span> , <span itemprop="about" itemscope itemtype="http://schema.org/Thing"> <a href="/categories/Site/Hexo/" itemprop="url" rel="index"><span itemprop="name">Hexo</span></a> </span> </span> <span class="post-meta-break"></span> <span class="post-meta-item" title="Word count in article"> <span class="post-meta-item-icon"> <i class="far fa-file-word"></i> </span> <span class="post-meta-item-text">Word count in article: </span> <span>1.5k</span> </span> <span class="post-meta-item" title="Reading time"> <span class="post-meta-item-icon"> <i class="far fa-clock"></i> </span> <span class="post-meta-item-text">Reading time ≈</span> <span>1 mins.</span> </span> </div> </div> </header> <div class="post-body" itemprop="articleBody"> <h1>hexo-related-popular-posts</h1> <p>Hexo is a fast, simple & powerful blog framework. It use plugins to provide features powerful APIs for limitless extensibility. Various plugins are available to support most template engines (EJS, Pug, Nunjucks, and many others). Easily integrate with existing NPM packages (Babel, PostCSS, Less/Sass, etc).</p> <p><code>hexo-related-popular-posts</code> plugin is a hexo plugin that generates a list of links to related posts or popular posts.</p> <h2 id="Installation">Installation</h2> <p>Use <code>npm</code> to install <code>hexo-related-popular-posts</code> package.</p> <figure class="highlight shell"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br></pre></td><td class="code"><pre><span class="line"><span class="meta prompt_">$ </span><span class="language-bash">npm install hexo-related-popular-posts --save</span></span><br><span class="line"><span class="meta prompt_"></span></span><br><span class="line"><span class="meta prompt_">$ </span><span class="language-bash">hexo clean</span></span><br></pre></td></tr></table></figure> <h2 id="Configuration">Configuration</h2> <p>This plugin integrated in «NexT», you may adjust options in NexT config:</p> <figure class="highlight yaml"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br><span class="line">8</span><br><span class="line">9</span><br><span class="line">10</span><br><span class="line">11</span><br><span class="line">12</span><br><span class="line">13</span><br><span class="line">14</span><br><span class="line">15</span><br><span class="line">16</span><br></pre></td><td class="code"><pre><span class="line"><span class="comment"># _config.next.yml</span></span><br><span class="line"></span><br><span class="line"><span class="comment"># Related popular posts</span></span><br><span class="line"><span class="comment"># Dependencies: https://github.com/tea3/hexo-related-popular-posts</span></span><br><span class="line"><span class="attr">related_posts:</span></span><br><span class="line"> <span class="comment"># DoItYourself</span></span><br><span class="line"> <span class="comment"># enable: false</span></span><br><span class="line"> <span class="attr">enable:</span> <span class="literal">true</span></span><br><span class="line"> <span class="attr">title:</span> <span class="comment"># Custom header, leave empty to use the default one</span></span><br><span class="line"> <span class="attr">display_in_home:</span> <span class="literal">false</span></span><br><span class="line"> <span class="attr">params:</span></span><br><span class="line"> <span class="attr">maxCount:</span> <span class="number">5</span></span><br><span class="line"> <span class="comment">#PPMixingRate: 0.0</span></span><br><span class="line"> <span class="comment">#isDate: false</span></span><br><span class="line"> <span class="comment">#isImage: false</span></span><br><span class="line"> <span class="comment">#isExcerpt: false</span></span><br></pre></td></tr></table></figure> <h2 id="Usage">Usage</h2> <p>If tags are included in the article, related articles can be displayed as a list. For example, add a tag like the following markdown file.</p> <figure class="highlight yaml"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br><span class="line">8</span><br><span class="line">9</span><br></pre></td><td class="code"><pre><span class="line"><span class="meta">---</span></span><br><span class="line"><span class="attr">title:</span> <span class="string">Hello</span> <span class="string">World</span></span><br><span class="line"><span class="attr">tags:</span></span><br><span class="line"> <span class="bullet">-</span> <span class="string">program</span></span><br><span class="line"> <span class="bullet">-</span> <span class="string">diary</span></span><br><span class="line"> <span class="bullet">-</span> <span class="string">web</span></span><br><span class="line"><span class="meta">---</span></span><br><span class="line"><span class="string">Welcome</span> <span class="string">to</span> [<span class="string">Hexo</span>]<span class="string">(https://hexo.io/)!</span> <span class="string">This</span> <span class="string">is</span> <span class="string">a</span> <span class="string">sample</span> <span class="string">article.</span> <span class="string">Let's</span> <span class="string">add</span> <span class="string">some</span> <span class="string">tags</span> <span class="string">as</span> <span class="string">above.</span></span><br><span class="line"><span class="string">...</span></span><br></pre></td></tr></table></figure> <p>Finally, you can visit your site in the browser, and check whether the site works correctly after Hexo restarted or regenerated.</p> <h2 id="References">References</h2> <p>[1] <a target="_blank" rel="noopener external nofollow noreferrer" href="https://github.com/tea3/hexo-related-popular-posts">GitHub - tea3/hexo-related-popular-posts: A hexo plugin that generates a list of links to related posts and popular posts. Also , this plugin can get Visitor Counts (PV) on posts. - https://github.com/tea3/hexo-related-popular-posts</a></p> <p>[2] <a target="_blank" rel="noopener external nofollow noreferrer" href="https://hexo.io/">Hexo - https://hexo.io/</a></p> </div> <footer class="post-footer"> <div class="post-eof"></div> </footer> </article> </div> <div class="post-block"> <article itemscope itemtype="http://schema.org/Article" class="post-content" lang=""> <link itemprop="mainEntityOfPage" href="https://cloudolife.com/2020/10/17/Kubernetes-K8S/Helm/Helm-install-nfs-server-provisioner-on-Kubernetes-K8S/"> <span hidden itemprop="author" itemscope itemtype="http://schema.org/Person"> <meta itemprop="image" content="/images/avatar.gif"> <meta itemprop="name" content="CloudoLife"> </span> <span hidden itemprop="publisher" itemscope itemtype="http://schema.org/Organization"> <meta itemprop="name" content="Cloud-oriented Life"> <meta itemprop="description" content="A Husband and Father, Knowledge Worker, Full-skilled Cloud Engineer"> </span> <span hidden itemprop="post" itemscope itemtype="http://schema.org/CreativeWork"> <meta itemprop="name" content="undefined | Cloud-oriented Life"> <meta itemprop="description" content=""> </span> <header class="post-header"> <h2 class="post-title" itemprop="name headline"> <a href="/2020/10/17/Kubernetes-K8S/Helm/Helm-install-nfs-server-provisioner-on-Kubernetes-K8S/" class="post-title-link" itemprop="url">[Kubernetes (K8S)] Helm install nfs-server-provisioner within Kubernetes (K8S)</a> </h2> <div class="post-meta-container"> <div class="post-meta"> <span class="post-meta-item"> <span class="post-meta-item-icon"> <i class="far fa-calendar"></i> </span> <span class="post-meta-item-text">Posted on</span> <time title="Created: 2020-10-17 00:00:00" itemprop="dateCreated datePublished" datetime="2020-10-17T00:00:00+00:00">2020-10-17</time> </span> <span class="post-meta-item"> <span class="post-meta-item-icon"> <i class="far fa-calendar-check"></i> </span> <span class="post-meta-item-text">Edited on</span> <time title="Modified: 2024-09-12 09:35:58" itemprop="dateModified" datetime="2024-09-12T09:35:58+00:00">2024-09-12</time> </span> <span class="post-meta-item"> <span class="post-meta-item-icon"> <i class="far fa-folder"></i> </span> <span class="post-meta-item-text">In</span> <span itemprop="about" itemscope itemtype="http://schema.org/Thing"> <a href="/categories/Cloud-Native/" itemprop="url" rel="index"><span itemprop="name">Cloud Native</span></a> </span> , <span itemprop="about" itemscope itemtype="http://schema.org/Thing"> <a href="/categories/Cloud-Native/Kubernetes-K8S/" itemprop="url" rel="index"><span itemprop="name">Kubernetes (K8S)</span></a> </span> , <span itemprop="about" itemscope itemtype="http://schema.org/Thing"> <a href="/categories/Cloud-Native/Kubernetes-K8S/Helm/" itemprop="url" rel="index"><span itemprop="name">Helm</span></a> </span> </span> <span class="post-meta-break"></span> <span class="post-meta-item" title="Word count in article"> <span class="post-meta-item-icon"> <i class="far fa-file-word"></i> </span> <span class="post-meta-item-text">Word count in article: </span> <span>7.4k</span> </span> <span class="post-meta-item" title="Reading time"> <span class="post-meta-item-icon"> <i class="far fa-clock"></i> </span> <span class="post-meta-item-text">Reading time ≈</span> <span>7 mins.</span> </span> </div> </div> </header> <div class="post-body" itemprop="articleBody"> <h1>helm-nfs-server-provisioner-example</h1> <h2 id="NFS-Server-Provisioner">NFS Server Provisioner</h2> <p><a target="_blank" rel="noopener external nofollow noreferrer" href="https://github.com/helm/charts/tree/master/stable/nfs-client-provisioner">nfs-client-provisioner - https://github.com/helm/charts/tree/master/stable/nfs-client-provisioner</a> is an out-of-tree dynamic provisioner for Kubernetes. You can use it to quickly & easily deploy shared storage that works almost anywhere throught Network File System (NFS).</p> <p>This chart will deploy the Kubernetes nfs provisioner. This provisioner includes a built in NFS server, and is not intended for connecting to a pre-existing NFS server. If you have a pre-existing NFS Server, please consider using the <a target="_blank" rel="noopener external nofollow noreferrer" href="https://github.com/helm/charts/tree/master/stable/nfs-client-provisioner">nfs-client-provisioner - https://github.com/helm/charts/tree/master/stable/nfs-client-provisioner</a> instead.</p> <p>This article is about how to use Helm to install nfs-server-provisioner on Kubernetes (K8S).</p> <!--noindex--> <div class="post-button"> <a class="btn" href="/2020/10/17/Kubernetes-K8S/Helm/Helm-install-nfs-server-provisioner-on-Kubernetes-K8S/#more" rel="contents"> Read more » </a> </div> <!--/noindex--> </div> <footer class="post-footer"> <div class="post-eof"></div> </footer> </article> </div> <div class="post-block"> <article itemscope itemtype="http://schema.org/Article" class="post-content" lang=""> <link itemprop="mainEntityOfPage" href="https://cloudolife.com/2020/10/17/Site/Hexo/Use-hexo-filter-nofollow-plugin-to-add-nofollow-attribute-to-all-external-links-automatically-in-Hexo/"> <span hidden itemprop="author" itemscope itemtype="http://schema.org/Person"> <meta itemprop="image" content="/images/avatar.gif"> <meta itemprop="name" content="CloudoLife"> </span> <span hidden itemprop="publisher" itemscope itemtype="http://schema.org/Organization"> <meta itemprop="name" content="Cloud-oriented Life"> <meta itemprop="description" content="A Husband and Father, Knowledge Worker, Full-skilled Cloud Engineer"> </span> <span hidden itemprop="post" itemscope itemtype="http://schema.org/CreativeWork"> <meta itemprop="name" content="undefined | Cloud-oriented Life"> <meta itemprop="description" content=""> </span> <header class="post-header"> <h2 class="post-title" itemprop="name headline"> <a href="/2020/10/17/Site/Hexo/Use-hexo-filter-nofollow-plugin-to-add-nofollow-attribute-to-all-external-links-automatically-in-Hexo/" class="post-title-link" itemprop="url">[Hexo] Use hexo-filter-nofollow plugin to add nofollow attribute to all external links automatically in Hexo</a> </h2> <div class="post-meta-container"> <div class="post-meta"> <span class="post-meta-item"> <span class="post-meta-item-icon"> <i class="far fa-calendar"></i> </span> <span class="post-meta-item-text">Posted on</span> <time title="Created: 2020-10-17 00:00:00" itemprop="dateCreated datePublished" datetime="2020-10-17T00:00:00+00:00">2020-10-17</time> </span> <span class="post-meta-item"> <span class="post-meta-item-icon"> <i class="far fa-calendar-check"></i> </span> <span class="post-meta-item-text">Edited on</span> <time title="Modified: 2024-09-12 09:35:58" itemprop="dateModified" datetime="2024-09-12T09:35:58+00:00">2024-09-12</time> </span> <span class="post-meta-item"> <span class="post-meta-item-icon"> <i class="far fa-folder"></i> </span> <span class="post-meta-item-text">In</span> <span itemprop="about" itemscope itemtype="http://schema.org/Thing"> <a href="/categories/Site/" itemprop="url" rel="index"><span itemprop="name">Site</span></a> </span> , <span itemprop="about" itemscope itemtype="http://schema.org/Thing"> <a href="/categories/Site/Hexo/" itemprop="url" rel="index"><span itemprop="name">Hexo</span></a> </span> , <span itemprop="about" itemscope itemtype="http://schema.org/Thing"> <a href="/categories/Site/Hexo/Hexo-Plugin/" itemprop="url" rel="index"><span itemprop="name">Hexo Plugin</span></a> </span> </span> <span class="post-meta-break"></span> <span class="post-meta-item" title="Word count in article"> <span class="post-meta-item-icon"> <i class="far fa-file-word"></i> </span> <span class="post-meta-item-text">Word count in article: </span> <span>1.7k</span> </span> <span class="post-meta-item" title="Reading time"> <span class="post-meta-item-icon"> <i class="far fa-clock"></i> </span> <span class="post-meta-item-text">Reading time ≈</span> <span>2 mins.</span> </span> </div> </div> </header> <div class="post-body" itemprop="articleBody"> <h1>hexo-filter-nofollow</h1> <p>Hexo is a fast, simple & powerful blog framework. It use plugins to provide features powerful APIs for limitless extensibility. Various plugins are available to support most template engines (EJS, Pug, Nunjucks, and many others). Easily integrate with existing NPM packages (Babel, PostCSS, Less/Sass, etc).</p> <p><code>hexo-filter-nofollow</code> plugin add <code>nofollow</code> attribute to all external links automatically.</p> <p><code>hexo-filter-nofollow</code> add `rel=“noopener external nofollow noreferrer” to all external links for security, privacy and SEO. Read more.</p> <h2 id="Installation">Installation</h2> <p>Use <code>npm</code> to install <code>hexo-filter-nofollow</code> package.</p> <figure class="highlight shell"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br></pre></td><td class="code"><pre><span class="line"><span class="meta prompt_">$ </span><span class="language-bash">npm install hexo-filter-nofollow --save</span></span><br><span class="line"><span class="meta prompt_"></span></span><br><span class="line"><span class="meta prompt_">$ </span><span class="language-bash">hexo clean</span></span><br></pre></td></tr></table></figure> <h2 id="Configuration">Configuration</h2> <p>It will generate sitemap.xml in the public folder by default after <code>hexo-filter-nofollow</code> installation.</p> <p>You can configure this plugin in <a href="./_config.yml">./_config.yml</a>.</p> <figure class="highlight yaml"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br></pre></td><td class="code"><pre><span class="line"><span class="attr">nofollow:</span></span><br><span class="line"> <span class="attr">enable:</span> <span class="literal">true</span></span><br><span class="line"> <span class="attr">field:</span> <span class="string">site</span></span><br><span class="line"> <span class="attr">exclude:</span></span><br><span class="line"> <span class="bullet">-</span> <span class="string">'exclude1.com'</span></span><br><span class="line"> <span class="bullet">-</span> <span class="string">'exclude2.com'</span></span><br></pre></td></tr></table></figure> <p>The follow is the options:</p> <ul> <li> <p>enable - Enable the plugin. Default value is true.</p> </li> <li> <p>field - The scope you want the plugin to proceed, can be ‘site’ or ‘post’. Default value is site.</p> <ul> <li> <p>‘post’ - Only add nofollow attribute to external links in your post content</p> </li> <li> <p>‘site’ - Add nofollow attribute to external links of whole sites</p> </li> </ul> </li> <li> <p>exclude - Exclude hostname. Specify subdomain when applicable, including www. ‘<a target="_blank" rel="noopener external nofollow noreferrer" href="http://exclude1.com">exclude1.com</a>’ does not apply to <a target="_blank" rel="noopener external nofollow noreferrer" href="http://www.exclude1.com">www.exclude1.com</a> nor <a target="_blank" rel="noopener external nofollow noreferrer" href="http://en.exclude1.com">en.exclude1.com</a>.</p> </li> </ul> <p>Finally, you can visit your site in the browser, and check whether the site works correctly after Hexo restarted or regenerated.</p> <h2 id="References">References</h2> <p>[1] <a target="_blank" rel="noopener external nofollow noreferrer" href="https://github.com/hexojs/hexo-filter-nofollow/">hexojs/hexo-filter-nofollow: Add nofollow attribute to all external links automatically. - https://github.com/hexojs/hexo-filter-nofollow/</a></p> <p>[2] <a target="_blank" rel="noopener external nofollow noreferrer" href="https://developer.mozilla.org/en-US/docs/Web/HTML/Link_types">Link types - HTML: HyperText Markup Language | MDN - https://developer.mozilla.org/en-US/docs/Web/HTML/Link_types</a></p> <p>[3] <a target="_blank" rel="noopener external nofollow noreferrer" href="https://developers.google.com/search/docs/advanced/guidelines/qualify-outbound-links">Qualify Outbound Links for SEO | Google Search Central - https://developers.google.com/search/docs/advanced/guidelines/qualify-outbound-links</a></p> <p>[4] <a target="_blank" rel="noopener external nofollow noreferrer" href="https://hexo.io/">Hexo - https://hexo.io/</a></p> </div> <footer class="post-footer"> <div class="post-eof"></div> </footer> </article> </div> <nav class="pagination"> <a class="extend prev" rel="prev" title="Previous page" aria-label="Previous page" href="/page/35/"><i class="fa fa-angle-left"></i></a><a class="page-number" href="/">1</a><span class="space">…</span><a class="page-number" href="/page/35/">35</a><span class="page-number current">36</span><a class="page-number" href="/page/37/">37</a><span class="space">…</span><a class="page-number" href="/page/58/">58</a><a class="extend next" rel="next" title="Next page" aria-label="Next page" href="/page/37/"><i class="fa fa-angle-right"></i></a> </nav> </div> </main> <footer class="footer"> <div class="footer-inner"> <div class="copyright"> © <span itemprop="copyrightYear">2024</span> <span class="with-love"> <i class="fa fa-heart"></i> </span> <span class="author" itemprop="copyrightHolder">CloudoLife</span> </div> <div class="wordcount"> <span class="post-meta-item"> <span class="post-meta-item-icon"> <i class="fa fa-chart-line"></i> </span> <span title="Word count total">2.6m</span> </span> <span class="post-meta-item"> <span class="post-meta-item-icon"> <i class="fa fa-coffee"></i> </span> <span title="Reading time total">39:34</span> </span> </div> <div class="busuanzi-count"> <span class="post-meta-item" id="busuanzi_container_site_uv"> <span class="post-meta-item-icon"> <i class="fa fa-user"></i> </span> <span class="site-uv" title="Total Visitors"> <span id="busuanzi_value_site_uv"></span> </span> </span> <span class="post-meta-item" id="busuanzi_container_site_pv"> <span class="post-meta-item-icon"> <i class="fa fa-eye"></i> </span> <span class="site-pv" title="Total Views"> <span id="busuanzi_value_site_pv"></span> </span> </span> </div> <div class="powered-by">Powered by <a href="https://hexo.io/" rel="noopener external nofollow noreferrer" target="_blank">Hexo</a> & <a href="https://theme-next.js.org/pisces/" rel="noopener external nofollow noreferrer" target="_blank">NexT.Pisces</a> </div> </div> </footer> <div class="toggle sidebar-toggle" role="button"> <span class="toggle-line"></span> <span class="toggle-line"></span> <span class="toggle-line"></span> </div> <div class="sidebar-dimmer"></div> <div class="back-to-top" role="button" aria-label="Back to top"> <i class="fa fa-arrow-up fa-lg"></i> <span>0%</span> </div> <div class="reading-progress-bar"></div> <a role="button" class="book-mark-link book-mark-link-fixed"></a> <noscript> <div class="noscript-warning">Theme NexT works best with JavaScript enabled</div> </noscript> <script src="https://cdnjs.cloudflare.com/ajax/libs/animejs/3.2.1/anime.min.js" integrity="sha256-XL2inqUJaslATFnHdJOi9GfQ60on8Wx1C2H8DYiN1xY=" crossorigin="anonymous"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/next-theme-pjax/0.6.0/pjax.min.js" integrity="sha256-vxLn1tSKWD4dqbMRyv940UYw4sXgMtYcK6reefzZrao=" crossorigin="anonymous"></script> <script src="/js/comments.js"></script><script src="/js/utils.js"></script><script src="/js/motion.js"></script><script src="/js/sidebar.js"></script><script src="/js/next-boot.js"></script><script src="/js/bookmark.js"></script><script src="/js/pjax.js"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/hexo-generator-searchdb/1.4.1/search.js" integrity="sha256-1kfA5uHPf65M5cphT2dvymhkuyHPQp5A53EGZOnOLmc=" crossorigin="anonymous"></script> <script src="/js/third-party/search/local-search.js"></script> <script class="next-config" data-name="pdf" type="application/json">{"object_url":{"url":"https://cdnjs.cloudflare.com/ajax/libs/pdfobject/2.3.0/pdfobject.min.js","integrity":"sha256-JJZNsid68vnh3/zyj0lY9BN5ynxVX/12XgOa1TlaYN0="},"url":"/lib/pdf/web/viewer.html"}</script> <script src="/js/third-party/tags/pdf.js"></script> <script data-pjax async src="https://busuanzi.ibruce.info/busuanzi/2.3/busuanzi.pure.mini.js"></script> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/gitalk/1.8.0/gitalk.css" integrity="sha256-AJnUHL7dBv6PGaeyPQJcgQPDjt/Hn/PvYZde1iqfp8U=" crossorigin="anonymous"> <script class="next-config" data-name="gitalk" type="application/json">{"enable":true,"github_id":"CloudoLife","repo":"col-hexo-CloudoLife.github.io","client_id":"4ca3ae8fb3a49237db9a","client_secret":"98d6652508799ef4350ab05aabe855e58f549112","admin_user":"benjamincloudolife","distraction_free_mode":true,"proxy":"https://cors-anywhere.azm.workers.dev/https://github.com/login/oauth/access_token","language":null,"js":{"url":"https://cdnjs.cloudflare.com/ajax/libs/gitalk/1.8.0/gitalk.min.js","integrity":"sha256-MVK9MGD/XJaGyIghSVrONSnoXoGh3IFxLw0zfvzpxR4="},"path_md5":"e1ff6b9b98e14cd2ee4d70ab357590aa"}</script> <script src="/js/third-party/comments/gitalk.js"></script> </body> </html>