Skip to content
play

GitHub Action

ArgoCD Sync Action

v0.2.0 Latest version

ArgoCD Sync Action

play

ArgoCD Sync Action

Sync your ArgoCD application from GitHub

Installation

Copy and paste the following snippet into your .yml file.

              

- name: ArgoCD Sync Action

uses: safe2008/argocd-app-actions@v0.2.0

Learn more about this action in safe2008/argocd-app-actions

Choose a version

ArgoCD Application Actions

GitHub Marketplace Actions Status Actions Status

This action will sync ArgoCD application.

Usage

Example workflow

This example replaces syncs ArgoCD application.

name: My Workflow
on: [ push, pull_request ]
jobs:
  build:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v2
      - name: Sync ArgoCD Application
        uses: safe2008/argocd-app-actions@main
        with:
          address: "vault.example.com"
          token: ${{ secrets.ARGOCD_TOKEN }}
          insecure: false
          appName: "my-example-app"

Inputs

Input Description
address ArgoCD server address.
token ArgoCD Token.
insecure ArgoCD insecure.
appName Application name to sync.

Examples

Sync Application

You can sync ArgoCD application after building an image etc.

name: My Workflow
on: [ push, pull_request ]
jobs:
  build:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v2
      - name: Sync ArgoCD Application
        uses: safe2008/argocd-app-actions@main
        with:
          address: "vault.example.com"
          token: ${{ secrets.ARGOCD_TOKEN }}
          insecure: false
          appName: "my-example-app"

Publishing

To publish a new version of this Action we need to update the Docker image tag in action.yml and also create a new release on GitHub.

  • Work out the next tag version number.
  • Update the Docker image in action.yml.
  • Create a new release on GitHub with the same tag.