-
Prerequisites (Windows WSL - Ubuntu)
- Install WSL, follow Microsoft official documentation
- Install Ubuntu OS <18.x.x from Microsoft Store
- In case of Docker manual installation, follow Docker official documentation
- Install a Text editor, in this case is recommended Visual Studio Code. Follow official docs
-
INSTRUCTIONS
- Clone the project locally in Ubuntu machine with Git command:
git clone https://github.com/dev-aarayav/devops-challenge.git
- Open folder "docker-scripts" and use script
nginx_setup.sh
- Run the following command before starting script:
sudo apt-get update && sudo apt upgrade -y
- Grant execution access to script:
$ chmod +x nginx_setup.sh
- Execution command for the script:
$ ./nginx_setup.sh nginx
- Run the following command and check if the Docker container is running:
$ docker ps
- Open a web browser and access http://localhost:8000 to see Nginx index web page running.
- Clone the project locally in Ubuntu machine with Git command:
-
Prerequisites (Windows WSL - Ubuntu)
- Install WSL, follow official documentation
- Install Ubuntu OS <18.x.x from Microsoft Store
- Minikube installation
- Minukube start official documentation
- Install a Text editor, in this case is recommended Visual Studio Code. Follow official docs
-
INSTRUCTIONS
- Clone the project locally in Ubuntu machine.
- Open folder "k8s-scripts" use script
k8s_harbor_deploy.sh
- Run the following command before starting script:
sudo apt-get update && sudo apt upgrade -y
- Grant execution access to script:
$ chmod +x k8s_harbor_deploy.sh
- Execution command for the script (No Arguments needed):
$ ./k8s_harbor_deploy.sh
NOTE: This script contains the complete logic. It installs Docker, Minikube, K8s tools & Helm. Then it deploys Harbor with Helm into Minikube cluster.
IMPORTANT NOTE
- Inside of directory
additional-scripts
you will find the following scripts:rm_k8s.sh
: If the installation goes wrong for any reason, this script removes K8s and minikube.get_helm.sh
: This script is to install Helm ONLY (But you can skip it because it's executed insidek8s_harbor_deploy.sh
).test_scrip
: It contains additional functions missing in principal script.
-
INSTRUCTIONS: After Installation
-
Validate that all K8s resources are up&running:
kubectl get pvc
: This should be executed for a namespace in specific to get all the volumes setup.kubectl get svc
: Shows ClusterIP that has the Harbor registry service running on port 5000TCP, 8080/TCPkubectl get ingress
: Shows the Ingress created to access Harbor using the localhostname setup in /etc/hosts path.kubectl get secrets
: Shows all the Secrets configured.kubectl describe secret <secret-name>
: Check the details of this secret and its content.
-
After executing the script, follow the steps below to confirm that everything is running:
- Open in yor browser the following link: https://harbor.local.registry.com
-