This Post includes Deploying an internal container registry using Digitalocean Kubernetes and Harbor. This is one of the best ways to get started to learn about Containers, Helm and Harbor
Here are few articles to have a TL-DR about Kubernetes
Deploy your app on Digitalocean
Deploying Microservices on Kubernetes
How to use Kubernetes to Expose your app
Creating a Kubernetes Cluster
Once Deployed you can download the k8s Configuration yaml file
After creating a cluster, you need to add an authentication token or certificate to your kubectl configuration file to connect.
Helm Package Manager
Helm Package manager is similar to Pip and Brew, and acts as a package manager to install different packages in Kubernetes. I have added the steps to install helm.
How to install Software on Helm
To Install Harbor you need to have Helm package manager.
Use this script wget https://raw.githubusercontent.com/farhankn/kube_challenge/main/helm.sh
to install helm and Harbor with the Default Credential
Install Trefik Ingress
This allows you to fix the issue were external IP was not getting assigned after we deploy the Harbor instance using Helm. I spend a considerable amount of time trying to troubleshoot how to fix including changing the expose type from ingress to nodeport and loadbalance.
helm repo add traefik https://helm.traefik.io/traefik
helm repo update
helm install traefik traefik/traefik
Install Harbor using Helm
Before we install harbor using helm , we need to define some of the values in a yaml file . I’ve mentioned the type as ingress and disabled TLS for simplicity of configuration. We need to specify the url and Credentialsthat will be used to access the application in the file. Once the yaml file has been created we can go ahead installing using helm with below commands.
helm repo add harbor https://helm.goharbor.io
helm repo update
helm install my-release harbor/harbor -f harbor.yaml
Once harbor install is complete , it can be access from URL specified in the harbor.yaml file. The below screenshot shows my deployed instance of harbor