This project is a simple static web page served through Kubernetes using:
- ✅ Minikube as the local cluster
- ✅ Argo CD for GitOps-based deployment
- ✅ NGINX Ingress Controller for routing HTTP traffic
- ✅ Docker for building the container image
web-app-gitops/
├── app/
│ ├── deployment.yaml # Web app deployment
│ ├── service.yaml # ClusterIP service exposing the app
│ └── ingress.yaml # Ingress resource (webapp.local)
│
├── argocd-app.yaml # argocd configs
├── index.html # Static HTML to serve
└── Dockerfile # Image that serves the HTML with Nginx
# Clone the repo and go inside
cd web-app-gitops
# Build your image
docker build -t aelmizeb/web-app:1.0.0 .
# Push to DockerHub
docker push aelmizeb/web-app:1.0.0
you can take a look to this to set up Minikube and ArgoCD on a Linux system : https://gist.github.com/aelmizeb/539f12687e551cef17b1fcfd14e19fb9
# Start Minikube with ingress support
minikube start
minikube addons enable ingress
# Check Ingress Controller is running
kubectl get pods -n ingress-nginx
# Create a namespace for ArgoCD
kubectl create namespace argocd
# Install ArgoCD (non-HA for local)
kubectl apply -n argocd -f https://raw.githubusercontent.com/argoproj/argo-cd/stable/manifests/install.yaml
# Port-forward the ArgoCD UI
kubectl port-forward svc/argocd-server -n argocd 8080:443
Now open http://localhost:8080 Default credentials:
- username: admin
- password: run the following CLI to get it
argocd admin initial-password -n argocd
Apply the configuration for ArgoCD
kubectl apply -f argocd-app.yaml -n argocd
Add to /etc/hosts:
echo "$(minikube ip) webapp.local" | sudo tee -a /etc/hosts
Then open: http://webapp.local
argocd app delete web-app --cascade
This command deletes the ArgoCD managed application named web-app
minikube delete
This completely deletes the entire Minikube cluster:
- Shuts down the Minikube virtual machine or container.
- Removes all pods, services, Ingresses, volumes, namespaces, configurations, etc.
- Essentially resets your local Kubernetes environment.
MIT License