Skip to main content

Tutorials

Here you can find some video tutorials on ArgoCD.

Note: these videos are in italian only

Basic Guides:

Advanced Guides:

Setting up ArgoCD Image Updater

ArgoCD Image Updater is a tool that enables automatic updates of Pods that use container images tagged latest. It is especially useful for development or test environments, where you want to immediately update to a newer dev release of your application.

The recommended way of using ArgoCD Image Updater is to install the chart argocd-image-updater from the repo https://argoproj.github.io/argo-helm through ArgoCD itself.

warning

If you're managing multiple clusters with a single ArgoCD instance, make sure to deploy ArgoCD Image Updater on the cluster where you have installed ArgoCD

Install ArgoCD Image Updater with these values:

config:
registries:
- name: ECR
api_url: https://100076361442.dkr.ecr.eu-south-1.amazonaws.com
prefix: 100076361442.dkr.ecr.eu-south-1.amazonaws.com
ping: yes
insecure: no
credentials: pullsecret:default/aws-ecr-regcred
credsexpire: 4h

After the installation, inside the ArgoCD UI go to the application you want to setup for automatic updates, then in the "Summary" tab go into edit mode and add annotations to enable automatic updates of your images.

In the following example, a microexecutor is configured for automatic updates:

argocd-image-updater.argoproj.io/image-list                         = me-java-as400proxy=100076361442.dkr.ecr.eu-south-1.amazonaws.com/kokos-java-as400proxy:latest
argocd-image-updater.argoproj.io/me-java-as400proxy.helm.image-name = kokos.microexecutors[8].image.name
argocd-image-updater.argoproj.io/me-java-as400proxy.helm.image-tag = kokos.microexecutors[8].image.tag
argocd-image-updater.argoproj.io/me-java-as400proxy.update-strategy = digest

Each annotation has a purpose:

  • argocd-image-updater.argoproj.io/image-list is used to declare aliases for images. In this example it's like we're declaring and instantiating a me-java-as400proxy variable with the value being the full image URI
  • argocd-image-updater.argoproj.io/me-java-as400proxy.helm.image-name tells ArgoCD Image updater where the image name should be put inside the values.yaml of the application we are updating. In the example our ME is the 9th element of the microexecutors array (look at kokos configurations for more info)
  • argocd-image-updater.argoproj.io/me-java-as400proxy.helm.image-tag same as the above annotation, but for the image tag
  • argocd-image-updater.argoproj.io/me-java-as400proxy.update-strategy tells ArgoCD Image updater the update strategy to use. We use digest which means that ArgoCD Image Updater will "update to the most recent pushed version of a mutable tag".

Migrating from Helm to ArgoCD

In the first releases of AHD (also known as Smartkit v2), Data or one of its components such as webup or restapi were installed directly through the Helm CLI. It is highly encouraged to migrate those Helm Releases to ArgoCD.

To migrate to ArgoCD, follow these steps:

  1. Make sure that you have ArgoCD installed (follow the first section of the AHD VM ArgoCD installation guide or the EKS guide depending on your environment)
  2. Take note of your current Helm Release name (visible through helm list) and values.yaml overrides.
  3. Create a new application through ArgoCD that is identical to the one currently installed through Helm. That means that the Name, Chart version and Values have to be the exact same.
  4. After creating the application, you should see that ArgoCD has picked up the existing kubernetes resources, with the ArgoCD Application being in OutOfSync status
  5. Run a SYNC process. The application should now be in Healthy and Synced status.
  6. You have successfully migrated to ArgoCD! 🥳
warning

After migrating to ArgoCD, you should not interact with the Helm Release through the CLI anymore! If you do, you risk deleting it permanently or causing configuration drift with ArgoCD.

Now that you've migrated Data to ArgoCD, you should repeat the process for AHD Commons to be able to manage both Applications through the ArgoCD interface, enabling you to easily update them and setup Continuous Deployment if you want to.