Skip to content

ArgoCD installation on Kubernetes

ArgoCD is installed into a Kubernetes cluster by applying the official installation manifests.^[400-devops-04-ci-cd-pipelines-k8s-argocd-argocd-app-config-readme.md, 400-devops__04-CI-CD-Pipelines__devops-ci__github-action__argocd-app-config__README.md]

Installation

The process begins by creating a dedicated namespace for ArgoCD, typically named argocd.^[400-devops-04-ci-cd-pipelines-k8s-argocd-argocd-app-config-readme.md, 400-devops__04-CI-CD-Pipelines__devops-ci__github-action__argocd-app-config__README.md]

Once the namespace exists, the core components are deployed by applying the installation manifest directly from the ArgoCD project's stable repository.^[400-devops-04-ci-cd-pipelines-k8s-argocd-argocd-app-config-readme.md, 400-devops__04-CI-CD-Pipelines__devops-ci__github-action__argocd-app-config__README.md]

[kubectl](<./kubectl.md>) create namespace [ArgoCD](<./argocd.md>)
[kubectl](<./kubectl.md>) apply -n [ArgoCD](<./argocd.md>) -f https://raw.githubusercontent.com/argoproj/argo-cd/stable/manifests/install.yaml

Accessing the UI

After installation, the ArgoCD UI can be accessed locally via [[Port Forwarding|port-forwarding]].^[400-devops-04-ci-cd-pipelines-k8s-argocd-argocd-app-config-readme.md, 400-devops__04-CI-CD-Pipelines__devops-ci__github-action__argocd-app-config__README.md]

This command forwards the local port 8080 to the ArgoCD server service (port 443) within the cluster.^[400-devops-04-ci-cd-pipelines-k8s-argocd-argocd-app-config-readme.md, 400-devops__04-CI-CD-Pipelines__devops-ci__github-action__argocd-app-config__README.md]

[kubectl](<./kubectl.md>) port-forward svc/argocd-server 8080:443 -n [ArgoCD](<./argocd.md>)

Initial Login

ArgoCD creates an initial admin user with a password stored in a Kubernetes Secret named argocd-initial-admin-secret.^[400-devops-04-ci-cd-pipelines-k8s-argocd-argocd-app-config-readme.md, 400-devops__04-CI-CD-Pipelines__devops-ci__github-action__argocd-app-config__README.md]

The following command retrieves and decodes this password for the first login.^[400-devops-04-ci-cd-pipelines-k8s-argocd-argocd-app-config-readme.md, 400-devops__04-CI-CD-Pipelines__devops-ci__github-action__argocd-app-config__README.md]

[kubectl](<./kubectl.md>) -n [ArgoCD](<./argocd.md>) get secret argocd-initial-admin-secret -o jsonpath="{.data.password}" | base64 --decode && echo

For security, it is recommended to change or delete this initial password after the first access.^[400-devops-04-ci-cd-pipelines-k8s-argocd-argocd-app-config-readme.md, 400-devops__04-CI-CD-Pipelines__devops-ci__github-action__argocd-app-config__README.md]

Sources

  • 400-devops-04-ci-cd-pipelines-k8s-argocd-argocd-app-config-readme.md
  • 400-devops__04-CI-CD-Pipelines__devops-ci__github-action__argocd-app-config__README.md