<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: neil wu</title>
    <description>The latest articles on DEV Community by neil wu (@neil_wu_174).</description>
    <link>https://dev.to/neil_wu_174</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F3532253%2Fd5cfc50e-79a4-4822-a583-3cc11fc2f1a0.png</url>
      <title>DEV Community: neil wu</title>
      <link>https://dev.to/neil_wu_174</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/neil_wu_174"/>
    <language>en</language>
    <item>
      <title>Programming Series in Rust</title>
      <dc:creator>neil wu</dc:creator>
      <pubDate>Mon, 29 Sep 2025 16:24:32 +0000</pubDate>
      <link>https://dev.to/neil_wu_174/programming-series-in-rust-357e</link>
      <guid>https://dev.to/neil_wu_174/programming-series-in-rust-357e</guid>
      <description>&lt;h2&gt;
  
  
  Rust Onwership
&lt;/h2&gt;

&lt;h4&gt;
  
  
  String,&amp;amp;String,str and &amp;amp;str
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;String
A dynamic piece of text stored on the heap at runtime.&lt;/li&gt;
&lt;li&gt;&amp;amp;String
A reference of the String stored on the heap. It is a variable contains the address of the string&lt;/li&gt;
&lt;li&gt;str
A hard-coded piece of text embeded in the binary code and it will loaded to the stack memory at runtime. It is part of your banary code.&lt;/li&gt;
&lt;li&gt;&amp;amp;str
A reference to a hard coded text in the binary. It holds the address of the str.&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  The Copy trait and Reference
&lt;/h4&gt;

&lt;p&gt;In Rust, if a type implements copy trait, Rust assignment statement(starting from let keyword) will make a copy of the variable. This is the fundimental rule to follow in Rust. Since referrence type implements copy trait, when you assign a reference to another variable, the variable will store the same address as the original reference variable.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;let dog: &amp;amp;str = "My dog's name is occean";
let another_dog: &amp;amp;str = dog;
dog variable holds the address of the string encoded in your binary on stack and another_dog will hold the same address since reference implements copy trait.
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h4&gt;
  
  
  Ownership and function parameters
&lt;/h4&gt;

&lt;p&gt;If you think of passing parameters to a function is like that you are assigning the variables with let keyword, then the same rules in Rust is applied in the function parameters. If a type implements the copy trait, then the parameter is a copy of the original variable and there is no ownership transfer. &lt;br&gt;
*&lt;strong&gt;&lt;em&gt;Note&lt;/em&gt;&lt;/strong&gt;*&lt;br&gt;
String type does not implements copy trait.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;fn perform(value: String) {
}
fn main() {
    let my_dog = "The name is Sun";
    perform(my_dog) -- ownership transfered to value.
    println!("{my_dog}") --- my_dog is not valid any more at this point.
}

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



</description>
      <category>programming</category>
      <category>rust</category>
      <category>tutorial</category>
    </item>
    <item>
      <title>Helm Chart Tutorial with your local kubernates</title>
      <dc:creator>neil wu</dc:creator>
      <pubDate>Sun, 28 Sep 2025 10:52:12 +0000</pubDate>
      <link>https://dev.to/neil_wu_174/helm-chart-tutorial-1jf5</link>
      <guid>https://dev.to/neil_wu_174/helm-chart-tutorial-1jf5</guid>
      <description>&lt;h2&gt;
  
  
  Install Helm CLI
&lt;/h2&gt;

&lt;p&gt;Follow the instruction at &lt;a href="https://helm.sh/docs/intro/install/" rel="noopener noreferrer"&gt;https://helm.sh/docs/intro/install/&lt;/a&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;sudo apt-get install curl gpg apt-transport-https --yes
curl -fsSL https://packages.buildkite.com/helm-linux/helm-debian/gpgkey | gpg --dearmor | sudo tee /usr/share/keyrings/helm.gpg &amp;gt; /dev/null
echo "deb [signed-by=/usr/share/keyrings/helm.gpg] https://packages.buildkite.com/helm-linux/helm-debian/any/ any main" | sudo tee /etc/apt/sources.list.d/helm-stable-debian.list
sudo apt-get update
sudo apt-get install helm
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Artifact Hub
&lt;/h2&gt;

&lt;p&gt;Artifact hub hosts publicly available helm chart to deploy the application to your kubernates.&lt;br&gt;
&lt;a href="https://artifacthub.io/" rel="noopener noreferrer"&gt;https://artifacthub.io/&lt;/a&gt;&lt;/p&gt;
&lt;h2&gt;
  
  
  helm repo command
&lt;/h2&gt;

&lt;p&gt;helm maintains a local cache of all the helm chart you downloaded, the command will add a helm chart info to your local cache&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;helm repo add bitnami https://charts.bitnami.com/bitnami 

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;To list your local cache&lt;br&gt;
helm repo list&lt;/p&gt;

&lt;p&gt;To update your local cache&lt;br&gt;
helm repo update&lt;/p&gt;

&lt;p&gt;To search helm chart from your local(the cache is located $HOME/.cache/helm/repository&lt;br&gt;
helm search repo wordpress&lt;/p&gt;

&lt;p&gt;To search helm chart from artifacthub&lt;br&gt;
helm search hub wordpress&lt;/p&gt;

&lt;p&gt;To show a specific helm chart&lt;br&gt;
helm show chart bitnami/wordpress&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;annotations:
  category: CMS
  images: |
    - name: apache-exporter
      image: docker.io/bitnami/apache-exporter:1.0.10-debian-12-r55
    - name: os-shell
      image: docker.io/bitnami/os-shell:12-debian-12-r50
    - name: wordpress
      image: docker.io/bitnami/wordpress:6.8.2-debian-12-r4
  licenses: Apache-2.0
  tanzuCategory: application
apiVersion: v2
appVersion: 6.8.2
dependencies:
- condition: memcached.enabled
  name: memcached
  repository: oci://registry-1.docker.io/bitnamicharts
  version: 7.x.x
- condition: mariadb.enabled
  name: mariadb
  repository: oci://registry-1.docker.io/bitnamicharts
  version: 22.x.x
- name: common
  repository: oci://registry-1.docker.io/bitnamicharts
  tags:
  - bitnami-common
  version: 2.x.x
description: WordPress is the world's most popular blogging and content management
  platform. Powerful yet simple, everyone from students to global corporations use
  it to build beautiful, functional websites.
home: https://bitnami.com
icon: https://dyltqmyl993wv.cloudfront.net/assets/stacks/wordpress/img/wordpress-stack-220x234.png
keywords:
- application
- blog
- cms
- http
- php
- web
- wordpress
maintainers:
- name: Broadcom, Inc. All Rights Reserved.
  url: https://github.com/bitnami/charts
name: wordpress
sources:
- https://github.com/bitnami/charts/tree/main/bitnami/wordpress
version: 26.0.0
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;From the above detailed output of the show command about the helm chart, you can use the following keywords defined in the helm chart to do the search&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;keywords:
- application
- blog
- cms
- http
- php
- web
- wordpress

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;helm search repo blog&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;NAME                    CHART VERSION   APP VERSION     DESCRIPTION
bitnami/ghost           25.0.4          6.0.5           Ghost is an open source publishing platform des...
bitnami/wordpress       26.0.0          6.8.2           WordPress is the world's most popular blogging ...
bitnami/wordpress-intel 2.1.31          6.1.1           DEPRECATED WordPress for Intel is the most popu...
bitnami/drupal          23.0.0          11.2.3          Drupal is one of the most versatile open source...
bitnami/joomla          20.0.4          5.1.2           DEPRECATED Joomla! is an award winning open sou...

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;helm search repo will only lists the latest version of the chart if you do not specify --versions. To list all the versions.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;neilwu@A8:~$ helm search repo wordpress --versions
NAME                    CHART VERSION   APP VERSION     DESCRIPTION
bitnami/wordpress       26.0.0          6.8.2           WordPress is the world's most popular blogging ...
bitnami/wordpress       25.0.26         6.8.2           WordPress is the world's most popular blogging ...
bitnami/wordpress       25.0.25         6.8.2           WordPress is the world's most popular blogging ...
bitnami/wordpress       25.0.24         6.8.2           WordPress is the world's most popular blogging ...
bitnami/wordpress       25.0.23         6.8.2           WordPress is the world's most popular blogging ...
bitnami/wordpress       25.0.15         6.8.2           WordPress is the world's most popular blogging ...

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;To remove a cached helm chart repo&lt;br&gt;
helm repo remove bitnami&lt;/p&gt;
&lt;h2&gt;
  
  
  Installing wordpress helm chart in your local kubernates
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Make sure your local kubernates is up and running
&lt;/li&gt;
&lt;/ul&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;neilwu@A8:~$ kubectl version
Client Version: v1.32.2
Kustomize Version: v5.5.0
Server Version: v1.32.2
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;


&lt;p&gt;If you see the above output, it means your local kubernates is up and running.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Make sure your current kubernates cluster is the current context
The kubectl config current-context command is used to display the name of the Kubernetes context currently in use by kubectl. This context determines which Kubernetes cluster and user kubectl interacts with.
&lt;/li&gt;
&lt;/ul&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;neilwu@A8:~$ kubectl config current-context
docker-desktop
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;


&lt;ul&gt;
&lt;li&gt;Install a helm chart&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Command format&lt;br&gt;
helm install [name] [helm chart name] --version=[version]&lt;br&gt;
For example, to install wordpress helm chart&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;helm install my-wp binami/wordpress --version=24.1.18
neilwu@A8:~$ helm install my-wp binami/wordpress --version=24.1.18
NAME: my-wp
LAST DEPLOYED: Sun Sep 28 08:06:47 2025
NAMESPACE: default
STATUS: deployed
REVISION: 1
TEST SUITE: None
NOTES:
CHART NAME: wordpress
CHART VERSION: 24.1.18
APP VERSION: 6.7.2

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Check the running pods&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;neilwu@A8:~$ kubectl get pods
NAME                              READY   STATUS    RESTARTS   AGE
cassandra-6bfbff8548-qd8n7        1/1     Running   0          34h
my-wp-mariadb-0                   1/1     Running   0          78s
my-wp-wordpress-bffd47846-fgr8b   1/1     Running   0          78s
postgres-795cdc86bf-wkwvj         1/1     Running   0          18h

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Name prefixed with my-wp is all the pods with the installation.&lt;/p&gt;

&lt;h2&gt;
  
  
  Explore the installed helm chart : wordpress
&lt;/h2&gt;

&lt;h3&gt;
  
  
  Check the services
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;neilwu@A8:~$ kubectl get svc
NAME                     TYPE           CLUSTER-IP       EXTERNAL-IP   PORT(S)                      AGE
cassandra-service        NodePort       10.97.53.48      &amp;lt;none&amp;gt;        9042:31082/TCP               33h
kubernetes               ClusterIP      10.96.0.1        &amp;lt;none&amp;gt;        443/TCP                      43h
my-wp-mariadb            ClusterIP      10.111.188.197   &amp;lt;none&amp;gt;        3306/TCP                     4m40s
my-wp-mariadb-headless   ClusterIP      None             &amp;lt;none&amp;gt;        3306/TCP                     4m40s
my-wp-wordpress          LoadBalancer   10.98.5.196      &amp;lt;pending&amp;gt;     80:31248/TCP,443:30684/TCP   4m40s
postgres                 ClusterIP      10.103.92.34     &amp;lt;none&amp;gt;        6432/TCP                     18h

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;ClusterIP is the default Service type that provides a stable, internal, virtual IP address for a set of Pods within the cluster, allowing other applications to access the service without external exposure. It functions as a load balancer, distributing incoming traffic to the various Pods that match the service's label selector, ensuring reliable communication and enabling applications to connect to services using a consistent, internal endpoint&lt;/p&gt;

&lt;p&gt;NodePort service provides external access to a Kubernetes service by opening a dedicated, high-numbered port on every node in the cluster, typically in the 30000-32767 range. Traffic sent to this port on any node is then forwarded by the kube-proxy to the service's internal port and then to one of its backend pod.&lt;/p&gt;

&lt;p&gt;LoadBalancer is a hardware device or software application that distributes incoming network traffic and workloads across multiple servers, acting as an intermediary to prevent any single server from becoming overloaded. This distribution ensures maximum resource utilization, reduces response times, improves application availability and reliability, and provides seamless maintenance for servers and applications.  &lt;/p&gt;

&lt;h3&gt;
  
  
  Check the secret
&lt;/h3&gt;

&lt;p&gt;neilwu@A8:~$ kubectl get secret&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;NAME                             TYPE                 DATA   AGE
my-wp-mariadb                    Opaque               2      13m
my-wp-wordpress                  Opaque               1      13m
sh.helm.release.v1.my-wp.v1      helm.sh/release.v1   1      13m
sh.helm.release.v1.postgres.v1   helm.sh/release.v1   1      18h

neilwu@A8:~$ kubectl describe secret my-wp-wordpress
Name:         my-wp-wordpress
Namespace:    default
Labels:       app.kubernetes.io/instance=my-wp
              app.kubernetes.io/managed-by=Helm
              app.kubernetes.io/name=wordpress
              app.kubernetes.io/version=6.7.2
              helm.sh/chart=wordpress-24.1.18
Annotations:  meta.helm.sh/release-name: my-wp
              meta.helm.sh/release-namespace: default

Type:  Opaque

Data
====
wordpress-password:  10 bytes

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Open a NodePort on the cluster node
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;neilwu@A8:~$ kubectl get svc
NAME                     TYPE           CLUSTER-IP       EXTERNAL-IP   PORT(S)                      AGE
cassandra-service        NodePort       10.97.53.48      &amp;lt;none&amp;gt;        9042:31082/TCP               37h
kubernetes               ClusterIP      10.96.0.1        &amp;lt;none&amp;gt;        443/TCP                      47h
my-wp-mariadb            ClusterIP      10.111.188.197   &amp;lt;none&amp;gt;        3306/TCP                     3h53m
my-wp-mariadb-headless   ClusterIP      None             &amp;lt;none&amp;gt;        3306/TCP                     3h53m
my-wp-wordpress          LoadBalancer   10.98.5.196      &amp;lt;pending&amp;gt;     80:31248/TCP,443:30684/TCP   3h53m
postgres                 ClusterIP      10.103.92.34     &amp;lt;none&amp;gt;        6432/TCP                     21h

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;





&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;neilwu@A8:~$ kubectl get deployment
NAME              READY   UP-TO-DATE   AVAILABLE   AGE
cassandra         1/1     1            1           39h
my-wp-wordpress   1/1     1            1           3h57m
postgres          1/1     1            1           21h

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now expose the deployment as a service(a type of NodePort)&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;neilwu@A8:~$ kubectl expose deploy my-wp-wordpress --type=NodePort --name my-wp
service/my-wp exposed
neilwu@A8:~$ kubectl get svc
NAME                     TYPE           CLUSTER-IP       EXTERNAL-IP   PORT(S)                         AGE
cassandra-service        NodePort       10.97.53.48      &amp;lt;none&amp;gt;        9042:31082/TCP                  37h
kubernetes               ClusterIP      10.96.0.1        &amp;lt;none&amp;gt;        443/TCP                         47h
my-wp                    NodePort       10.101.50.141    &amp;lt;none&amp;gt;        8080:32195/TCP,8443:30926/TCP   10s
my-wp-mariadb            ClusterIP      10.111.188.197   &amp;lt;none&amp;gt;        3306/TCP                        3h59m
my-wp-mariadb-headless   ClusterIP      None             &amp;lt;none&amp;gt;        3306/TCP                        3h59m
my-wp-wordpress          LoadBalancer   10.98.5.196      &amp;lt;pending&amp;gt;     80:31248/TCP,443:30684/TCP      3h59m
postgres                 ClusterIP      10.103.92.34     &amp;lt;none&amp;gt;        6432/TCP                        21h

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now wordpress is exposed to your host machine&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;my-wp                    NodePort       10.101.50.141    &amp;lt;none&amp;gt;        8080:32195/TCP,8443:30926/TCP   10s

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You can use &lt;a href="http://127.0.0.1:32195" rel="noopener noreferrer"&gt;http://127.0.0.1:32195&lt;/a&gt; to access wordpress home page hosted in a pod and &lt;a href="http://localhost:32195/wp-admin" rel="noopener noreferrer"&gt;http://localhost:32195/wp-admin&lt;/a&gt; is the admin console.&lt;/p&gt;

&lt;h2&gt;
  
  
  Explore the installed wordpress application
&lt;/h2&gt;

&lt;p&gt;kubectl get secret&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;neilwu@A8:~$ kubectl get secret
NAME                             TYPE                 DATA   AGE
my-wp-mariadb                    Opaque               2      4h37m
my-wp-wordpress                  Opaque               1      4h37m

neilwu@A8:~$ kubectl describe secret my-wp-wordpress
Name:         my-wp-wordpress
Namespace:    default
Labels:       app.kubernetes.io/instance=my-wp
              app.kubernetes.io/managed-by=Helm
              app.kubernetes.io/name=wordpress
              app.kubernetes.io/version=6.7.2
              helm.sh/chart=wordpress-24.1.18
Annotations:  meta.helm.sh/release-name: my-wp
              meta.helm.sh/release-namespace: default

Type:  Opaque

Data
====
wordpress-password:  10 bytes
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;wordpress-password is a 10 bytes long strings. Now it is time to decrypted&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;neilwu@A8:~$ kubectl get secret my-wp-wordpress -o jsonpath='{.data.wordpress-password}' | base64 -d
czrKG2tiamneilwu@A8:~$

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Eventually the username/password for the admin page &lt;a href="http://localhost:32195/wp-admin" rel="noopener noreferrer"&gt;http://localhost:32195/wp-admin&lt;/a&gt; will be &lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;username
user&lt;/li&gt;
&lt;li&gt;password
czrKG2tiam&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Uninstalling your helm chart
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;neilwu@A8:~$ helm list
NAME            NAMESPACE       REVISION        UPDATED                                 STATUS          CHART                   APP VERSION
my-wp           default         1               2025-09-28 08:06:47.682168282 -0400 EDT deployed        wordpress-24.1.18       6.7.2
postgres        default         1               2025-09-27 14:07:17.321804979 -0400 EDT deployed        postgres-0.1.0          1.16.0

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now uninstall my-wp&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;neilwu@A8:~$ helm uninstall my-wp
release "my-wp" uninstalled
neilwu@A8:~$ helm list
NAME            NAMESPACE       REVISION        UPDATED                                 STATUS          CHART           APP VERSION
postgres        default         1               2025-09-27 14:07:17.321804979 -0400 EDT deployed        postgres-0.1.0  1.16.0
neilwu@A8:~$ kubectl get pod
NAME                         READY   STATUS    RESTARTS   AGE
cassandra-6bfbff8548-qd8n7   1/1     Running   0          39h
postgres-795cdc86bf-wkwvj    1/1     Running   0          22h

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now check services&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;neilwu@A8:~$ kubectl get svc
NAME                TYPE        CLUSTER-IP      EXTERNAL-IP   PORT(S)                         AGE
cassandra-service   NodePort    10.97.53.48     &amp;lt;none&amp;gt;        9042:31082/TCP                  38h
kubernetes          ClusterIP   10.96.0.1       &amp;lt;none&amp;gt;        443/TCP                         2d
my-wp               NodePort    10.101.50.141   &amp;lt;none&amp;gt;        8080:32195/TCP,8443:30926/TCP   60m
postgres            ClusterIP   10.103.92.34    &amp;lt;none&amp;gt;        6432/TCP                        22h

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;There is still one service left called my-wp which we created manually. We need to delete this manually created in the kubectl expose command.&lt;br&gt;
To delete, issues kubectl delete svc my-wp&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;neilwu@A8:~$ kubectl delete svc my-wp
service "my-wp" deleted
neilwu@A8:~$ kubectl get svc
NAME                TYPE        CLUSTER-IP     EXTERNAL-IP   PORT(S)          AGE
cassandra-service   NodePort    10.97.53.48    &amp;lt;none&amp;gt;        9042:31082/TCP   38h
kubernetes          ClusterIP   10.96.0.1      &amp;lt;none&amp;gt;        443/TCP          2d
postgres            ClusterIP   10.103.92.34   &amp;lt;none&amp;gt;        6432/TCP         23h

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;To completely delete a helm chart, this is not the end. we also need to check if there are any pv(persistence volumn) and pvc(persistence volumn claim)&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;neilwu@A8:~$ kubectl get pv
NAME                                       CAPACITY   ACCESS MODES   RECLAIM POLICY   STATUS   CLAIM                                      STORAGECLASS   VOLUMEATTRIBUTESCLASS   REASON   AGE
pvc-774e680d-e1a6-4a5b-8b3a-f8acc6c1b9a3   4Gi        RWO            Delete           Bound    default/postgres-persistent-volume-claim   hostpath       &amp;lt;unset&amp;gt;                          23h
pvc-ba1c49f0-bdca-4da1-bbf0-7d00bc1d2579   8Gi        RWO            Delete           Bound    default/data-my-wp-mariadb-0               hostpath       &amp;lt;unset&amp;gt;                          5h5m
neilwu@A8:~$ kubectl get pvc
NAME                               STATUS   VOLUME                                     CAPACITY   ACCESS MODES   STORAGECLASS   VOLUMEATTRIBUTESCLASS   AGE
data-my-wp-mariadb-0               Bound    pvc-ba1c49f0-bdca-4da1-bbf0-7d00bc1d2579   8Gi        RWO            hostpath       &amp;lt;unset&amp;gt;                 5h6m
postgres-persistent-volume-claim   Bound    pvc-774e680d-e1a6-4a5b-8b3a-f8acc6c1b9a3   4Gi        RWO            hostpath       &amp;lt;unset&amp;gt;                 23h

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The output shows data-my-wp-mariadb-0 is the one to be deleted.&lt;br&gt;
Before deletion, check kubernates storage class&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;neilwu@A8:~$ kubectl describe storageclass
Name:            hostpath
IsDefaultClass:  Yes
Annotations:     kubectl.kubernetes.io/last-applied-configuration={"apiVersion":"storage.k8s.io/v1","kind":"StorageClass","metadata":{"annotations":{"storageclass.kubernetes.io/is-default-class":"true"},"name":"hostpath"},"provisioner":"docker.io/hostpath","reclaimPolicy":"Delete","volumeBindingMode":"Immediate"}
,storageclass.kubernetes.io/is-default-class=true
Provisioner:           docker.io/hostpath
Parameters:            &amp;lt;none&amp;gt;
AllowVolumeExpansion:  &amp;lt;unset&amp;gt;
MountOptions:          &amp;lt;none&amp;gt;
ReclaimPolicy:         Delete

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;ReclaimPolicy is set to Delete. It mains the pv can be reclaimed by delete action.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;neilwu@A8:~$ kubectl delete pvc data-my-wp-mariadb-0
persistentvolumeclaim "data-my-wp-mariadb-0" deleted
neilwu@A8:~$ kubectl get pv
NAME                                       CAPACITY   ACCESS MODES   RECLAIM POLICY   STATUS   CLAIM                                      STORAGECLASS   VOLUMEATTRIBUTESCLASS   REASON   AGE
pvc-774e680d-e1a6-4a5b-8b3a-f8acc6c1b9a3   4Gi        RWO            Delete           Bound    default/postgres-persistent-volume-claim   hostpath       &amp;lt;unset&amp;gt;                          23h
neilwu@A8:~$ kubectl get pvc
NAME                               STATUS   VOLUME                                     CAPACITY   ACCESS MODES   STORAGECLASS   VOLUMEATTRIBUTESCLASS   AGE
postgres-persistent-volume-claim   Bound    pvc-774e680d-e1a6-4a5b-8b3a-f8acc6c1b9a3   4Gi        RWO            hostpath       &amp;lt;unset&amp;gt;                 23h

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



</description>
      <category>kubernetes</category>
      <category>tutorial</category>
      <category>devops</category>
      <category>cli</category>
    </item>
    <item>
      <title>Setup Jfrog OSS in WSL2 on Windows 11 Pro</title>
      <dc:creator>neil wu</dc:creator>
      <pubDate>Sat, 27 Sep 2025 19:21:15 +0000</pubDate>
      <link>https://dev.to/neil_wu_174/setup-jfrog-oss-in-wsl2-on-windows-11-pro-1jcm</link>
      <guid>https://dev.to/neil_wu_174/setup-jfrog-oss-in-wsl2-on-windows-11-pro-1jcm</guid>
      <description>&lt;h2&gt;
  
  
  Install Jfrog OSS from docker
&lt;/h2&gt;

&lt;p&gt;docker pull docker.bintray.io/jfrog/artifactory-oss:latest&lt;/p&gt;

&lt;h2&gt;
  
  
  Create a folder under windows 11 Pro
&lt;/h2&gt;

&lt;p&gt;c:/apps/jfrog/artifactory&lt;br&gt;
It will be mapped to /mnt/c/apps/jfrog/artifactory under WSL2(Ubentu)&lt;/p&gt;

&lt;h2&gt;
  
  
  Start JFrog Artifactory container
&lt;/h2&gt;

&lt;p&gt;To start an Artifactory container, use the command:&lt;/p&gt;

&lt;p&gt;docker run --name artifactory -d \&lt;br&gt;
  -p 8081:8081 \&lt;br&gt;
  -p 8082:8082 \&lt;br&gt;
  -v /mnt/c/apps/jfrog/artifactory:/var/opt/jfrog/artifactory \&lt;br&gt;
  docker.bintray.io/jfrog/artifactory-cpp-ce&lt;/p&gt;

&lt;p&gt;You can pass Java system properties to the JVM running Artifactory using EXTRA_JAVA_OPTIONS. Check more on Docker setup link. See example below.&lt;/p&gt;

&lt;p&gt;docker run --name artifactory -d \&lt;br&gt;
  -p 8081:8081 \&lt;br&gt;
  -p 8082:8082 \&lt;br&gt;
  -v /jfrog/artifactory:/var/opt/jfrog/artifactory \&lt;br&gt;
  -e EXTRA_JAVA_OPTIONS='-Xms512m -Xmx2g -Xss256k -XX:+UseG1GC' \&lt;br&gt;
  docker.bintray.io/jfrog/artifactory-pro:latest&lt;/p&gt;

</description>
      <category>docker</category>
      <category>tutorial</category>
      <category>devops</category>
      <category>linux</category>
    </item>
    <item>
      <title>Use Helm with local Kubernates created in Docker desktop</title>
      <dc:creator>neil wu</dc:creator>
      <pubDate>Sat, 27 Sep 2025 17:09:51 +0000</pubDate>
      <link>https://dev.to/neil_wu_174/use-helm-with-local-kubernates-created-in-docker-desktop-24ll</link>
      <guid>https://dev.to/neil_wu_174/use-helm-with-local-kubernates-created-in-docker-desktop-24ll</guid>
      <description>&lt;h2&gt;
  
  
  Install Helm on ubuntu
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;sudo apt-get install curl gpg apt-transport-https --yes
curl -fsSL https://packages.buildkite.com/helm-linux/helm-debian/gpgkey | gpg --dearmor | sudo tee /usr/share/keyrings/helm.gpg &amp;gt; /dev/null
echo "deb [signed-by=/usr/share/keyrings/helm.gpg] https://packages.buildkite.com/helm-linux/helm-debian/any/ any main" | sudo tee /etc/apt/sources.list.d/helm-stable-debian.list
sudo apt-get update
sudo apt-get install helm

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



</description>
    </item>
    <item>
      <title>Building a functional kubernate cluster with docker desktop on windows 11 pro</title>
      <dc:creator>neil wu</dc:creator>
      <pubDate>Fri, 26 Sep 2025 16:38:02 +0000</pubDate>
      <link>https://dev.to/neil_wu_174/building-a-functional-kubernate-cluster-with-docker-desktop-on-windows-11-pro-1d7h</link>
      <guid>https://dev.to/neil_wu_174/building-a-functional-kubernate-cluster-with-docker-desktop-on-windows-11-pro-1d7h</guid>
      <description>&lt;h2&gt;
  
  
  Installation the latest docker desktop
&lt;/h2&gt;

&lt;p&gt;Download the docker desktop binary from &lt;a href="https://docs.docker.com/desktop/setup/install/windows-install/" rel="noopener noreferrer"&gt;https://docs.docker.com/desktop/setup/install/windows-install/&lt;/a&gt; for your windows 11 Pro, then follow the instruction to install the application.&lt;/p&gt;

&lt;h2&gt;
  
  
  Configuration the installed docker desktop
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;Enable the host networking&lt;br&gt;
Settings -&amp;gt; Resources -&amp;gt; Network&lt;br&gt;
Enable host networking&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Enable the kubernates&lt;br&gt;
Settings -&amp;gt; Kubernates -&amp;gt; Enable Kubernates&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Create a single node kubernate cluster&lt;br&gt;
Settings -&amp;gt; Kubernates -&amp;gt; Cluster settings -&amp;gt; Kubeadm&lt;br&gt;
Click apply to create a single node cluster&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Check created cluster&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;kubectl cluster-info&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Kubernetes control plane is running at https://kubernetes.docker.internal:6443
CoreDNS is running at https://kubernetes.docker.internal:6443/api/v1/namespaces/kube-system/services/kube-dns:dns/proxy

To further debug and diagnose cluster problems, use 'kubectl cluster-info dump
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Deploy a cassandra to the cluster
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Create a deployment yaml file
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;apiVersion: apps/v1
kind: Deployment
metadata:
  name: cassandra
  labels:
    app: cassandra
spec:
  replicas: 1
  selector:
    matchLabels:
      app: cassandra
  template:
    metadata:
      labels:
        app: cassandra
    spec:
      containers:
      - name: cassandra
        image: cassandra:4.1
        ports:
        - containerPort: 9042
        env:
        - name: CASSANDRA_CLUSTER_NAME
          value: "CassandraCluster"
        - name: MAX_HEAP_SIZE
          value: "512M"ply -
        - name: HEAP_NEWSIZE
          value: "100M"
        volumeMounts:
        - name: cassandra-data
          mountPath: /var/lib/cassandra
      volumes:
      - name: cassandra-data
        emptyDir: {}


&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;Deploy cassandra from a deployment yaml file
kubectl apply -f cassandra.yaml
After successfully executes the above command, check if cassandra pod is up and running.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;kubectl get pods&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;neilwu@A8:~/apps/kubernates/deployment$ kubectl get pods
NAME                         READY   STATUS    RESTARTS   AGE
cassandra-6bfbff8548-qd8n7   1/1     Running   0          25m

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Excellent !, your first cassandra pod is up and running.&lt;/p&gt;

</description>
    </item>
  </channel>
</rss>
