- Make sure you have repository with some Kubernetes manifests
- Make sure you have a Kubernetes cluster running with ArgoCD installed
- Create a new application using the UI or CLI
- App Name: app-demo
- Project: project-demo
- Kubernetes namespace: default
- Sync the application
- Verify the application is running by executing
kubectl get deploy
in thedefault
namespace - Now make a change in your repository to one of the Kubernetes manifests (e.g. update deployment tag)
- Go back to ArgoCD and check the state of the app
- Sync the state of the application
Click here to view the solution
- Click on "New App"
- Insert application name:
app-demo
- Insert project:
project-demo
- Under source put the repository URL to your GitHub repo with Kubernetes manifests
- Set path of your application
- Under destination put the address of your Kubernetes cluster and set namespace to
default
- Click on "Create"
- Insert application name:
- Click on the newly created application
- Click on the "sync button" and click on "Synchronize"
- Make a change in your Git repo where the Kubernetes manifests are
git add .
git commit -a
git push origin <BRANCH_NAME>
- Go back to ArgoCD UI and check the status of the app
- You should see it's "out-of-sync". If you don't, you may want to click on "Refresh"
- You can also click on "App diff" to see the difference that led to "out-of-sync"
- Click on "Sync" and "Synchronize" to sync the application
argocd app create app-demo \
--project project-demo \
--repo https://fake.repo.address \
--path ./some_app_path \
--dest-namespace default \
--dest-server my.kubernetes.cluster
# In the Git repo
cd <git repo>
vi <k8s manifest>
git add .
git commit -a
git push origin <BRANCH_NAME>
# Check app state
argocd app get app-demo
# Sync app state
argocd app sync app-demo
argocd app wait app-demo