This project was developed to practice deploying web applications with Kubernetes.
During the development of this project, the following techologies were used:
Here's a list of useful commands for minikube and the Kubernetes CLI (kubectl):
$ minikube start --driver docker # Pulls image and creates container for minikube with Docker
$ minikube status # Checks the minikube cluster status
$ minikube ip # Shows current minikube IP address
$ minikube stop # Stops the minikube cluster
$ minikube service webapp-service # Runs the webapp service when minikube IP is not accessible (it's a known issue)
$ kubectl get node # Shows current nodes
$ kubectl apply -f <config.yaml> # Applies a configuration (.yaml) file for cluster
$ kubectl get pod # Shows current cluster Pods
$ kubectl get svc # Shows current cluster services
$ kubectl get all # Shows all cluster components
$ kubectl get configmap # Shows cluster config maps
$ kubectl get secret # Shows cluster secrets
$ kubectl describe service <service-name> # Shows details about the service
$ kubectl describe pod <pod-name> # Shows details about the pod
$ kubectl logs <pod-name> # Shows logs for the pod/container (we can stream the logs with the -f option at the end of the command)
To deploy the application in a development environment, execute the following command on the root directory.
$ kubectl apply -f mongo-config.yaml
$ kubectl apply -f mongo-secret.yaml
$ kubectl apply -f mongo.yaml
$ kubectl apply -f webapp.yaml
- Kubernetes Crash Course for Absolute Beginners [NEW]
- minikube start
- Kubernetes Documentation
- developing-with-docker
This project is under the MIT license. For more information, access LICENSE.