How yafan11/kubernetes-argo-cd-gitops-hello-time-app works
Project type and purpose
• This is a simple, containerized web application (“Hello Time App”) whose sole function is to display the current time in a browser.
• It demonstrates GitOps best-practices by using Argo CD to continuously deploy the application to a Kubernetes cluster.
File structure
• Top level:
• LICENSE, README.md
• hello-time-app/ (application source & Docker assets)
• img/ (any illustrative assets)
• k8s/ (Kubernetes manifests and Argo CD namespace YAML)
• hello-time-app/:
• Dockerfile & .dockerignore → container build context
• hello-time-app.conf → Nginx configuration
• index.html → static web page showing time
• k8s/:
• argocd-namespace.yaml → defines the Argo CD installation namespace
• hello-time-app-deployment.yaml → Deployment spec for the Nginx-based container
• hello-time-app-service.yaml → Service exposing the Pod
Key insights from the README
• Technologies: Docker, Nginx, Kubernetes, Argo CD, Git
• Workflow:
1. Developer commits code/manifests to GitHub
2. Argo CD watches the repo path
3. Argo CD syncs manifests into the cluster
• Outcome: a running Nginx Pod serving index.html, reachable via a Kubernetes Service (LoadBalancer/Ingress).
a. Main components
• Developer Git repository (GitHub)
• Continuous Delivery controller (Argo CD server + repo server)
• Container registry (implicit: Docker Hub or private registry)
• Kubernetes cluster
– Control plane (API server, etcd)
– hello-time-app Namespace
– Deployment → Pod running Nginx + index.html
– Service → ClusterIP/LoadBalancer exposing Pod
• (Optional) Ingress / LoadBalancer for external traffic
b. Relationships and interactions
1. Developer → Push to GitHub
2. Argo CD GitOps loop: GitHub → Argo CD (detects change) → K8s API Server (applies manifests)
3. Kubernetes scheduler pulls container image from registry → Pod
4. Client traffic → LoadBalancer/Ingress → Service → Pod
c. Architectural patterns & design principles
– GitOps: declarative manifests in Git drive cluster state
– Immutable container images for reproducibility
– Separation of concerns:
• Application code vs. infrastructure manifests
• Control plane vs. data plane
d. Key technologies
– Docker (image build)
– Nginx (web server)
– Kubernetes (orchestration)
– Argo CD (GitOps CD)
– GitHub (source of truth)