This project demonstrates a complete, production-grade CI/CD pipeline for deploying a Go web application to an AWS EKS Kubernetes cluster, fully automated via GitHub Actions, Helm, and Argo CD following GitOps best practices.
- Go (Golang) β Web application
- Docker β Containerization
- Helm β Kubernetes manifest packaging
- Kubernetes on AWS EKS β Orchestration
- NGINX Ingress Controller β Traffic routing
- GitHub Actions β CI/CD automation
- Argo CD β GitOps deployment and synchronization
- DockerHub β Container image repository
- AWS account & EKS cluster configured
- Argo CD installed and accessible
- DockerHub or AWS ECR credentials for pushing images
kubectl
,helm
,argocd
CLI tools installed- DNS record configured for your Ingress (e.g.,
go-web-app.local
)
Develop your Go application:
// main.go package main import ( "log" "net/http" ) func homePage(w http.ResponseWriter, r *http.Request) { // Render the home html page from static folder http.ServeFile(w, r, "static/home.html") }
Build and test locally:
docker build -t narcisse198/go-web-app:latest . docker run -p 8080:8080 narcisse198/go-web-app:latest
On push to main
, the CI/CD pipeline runs via GitHub Actions:
# .github/workflows/ci.yml (simplified) name: CI/CD on: push: branches: - main jobs: build-and-push: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 - uses: actions/setup-go@v2 with: go-version: 1.21.11 - run: go build -o go-web-app - run: go test ./... - uses: docker/setup-buildx-action@v1 - uses: docker/login-action@v3 with: username: ${{ secrets.DOCKERHUB_USERNAME }} password: ${{ secrets.DOCKERHUB_TOKEN }} - uses: docker/build-push-action@v6 with: context: . push: true tags: ${{ secrets.DOCKERHUB_USERNAME }}/go-web-app:${{ github.run_id }}
GitHub Actions workflow successful β‘οΈ
DockerHub image pushed with tag β‘οΈ
The Helm chart deploys your app on EKS.
values.yaml snippet:
image: repository: narcisse198/go-web-app tag: "<UPDATED BY CI/CD>"
Helm defines:
β
Deployment
β
Service
β
Ingress
Helm values updated with image tag β‘οΈ
Argo CD continuously monitors Git repository:
argocd.yaml (removed from the project)
apiVersion: argoproj.io/v1alpha1 kind: Application metadata: name: go-web-app spec: source: repoURL: https://github.com/NarcisseObadiah/GO-Wep-App path: charts/go-web-app-chart targetRevision: HEAD destination: server: https://kubernetes.default.svc namespace: go-web-app syncPolicy: automated: prune: true selfHeal: true
Once your Helm values are updated by CI/CD, Argo CD automatically syncs the changes to EKS.
Argo CD UI showing app healthy & synced β‘οΈ
Your service is exposed via NGINX Ingress:
apiVersion: networking.k8s.io/v1 kind: Ingress metadata: name: go-web-app spec: ingressClassName: nginx rules: - host: go-web-app.local http: paths: - path: / pathType: Prefix backend: service: name: go-web-app port: number: 80
Update your DNS to point go-web-app.local
to the EKS Load Balancer.
πΌ** Browser accessing go-web-app.local
β‘οΈ
πΌ** EKS console with cluster running β‘οΈ
πΌοΈ** Terminal output of kubectl get deploy, kubectl get svc, kubectl get ingress
β‘οΈ
- β Prometheus & Grafana for monitoring
- β Sealed Secrets or AWS Secrets Manager for secret management
- β Security scans with Trivy or Snyk
Narcisse Obadiah
Software Engineer | Cloud-Native Enthusiast
This project showcases:
βοΈ Scalable Go app deployment on Kubernetes
βοΈ Full CI/CD pipeline with image building & Helm automation
βοΈ GitOps approach via Argo CD
βοΈ Clear, modular, production-grade structure