Argo CD Upgrade/Install #5
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: "Argo CD Upgrade/Install" | |
on: | |
workflow_dispatch: | |
inputs: | |
target-environment: | |
type: choice | |
description: Target environment for Argo CD | |
options: | |
- KUBEPI | |
- GKE | |
loft-cli-version: | |
description: 'Loft CLI version to use' | |
default: "v3.2.4" | |
env: | |
LOFT_CLI_VERSION: ${{ inputs.loft-cli-version || 'v3.2.4' }} | |
GITHUB_ENV: ${{ inputs.target-environment || 'KUBEPI' }} | |
jobs: | |
upgrade-install: | |
name: upgrade-install-argocd | |
environment: $GITHUB_ENV | |
runs-on: arc-runner-set | |
permissions: | |
id-token: write | |
contents: read | |
steps: | |
- id: checkout | |
uses: actions/checkout@v4 | |
- id: install-loft-cli | |
uses: loft-sh/setup-loft@v2 | |
with: | |
version: ${{ env.LOFT_CLI_VERSION }} | |
url: ${{ vars.LOFT_URL }} | |
insecure: true | |
# Specify your Loft access key here | |
access-key: ${{ secrets.LOFT_ACCESS_KEY }} | |
- id: argocd-upgrade-install | |
run: | | |
loft use cluster loft-cluster | |
helm repo add argo https://argoproj.github.io/argo-helm | |
helm repo update | |
helm upgrade --install argocd argo/argo-cd \ | |
-n argocd --create-namespace --version 5.42.2 --wait \ | |
--set configs.secret.githubSecret=${{ secrets.ARGOCD_GITHUB_WEBHOOK_SECRET }} \ | |
--set ingress.hosts[0].host=argocd.${{ vars.BASE_HOST }} \ | |
--set ingress.tls[0].hosts[0]=argocd.${{ vars.BASE_HOST }} \ | |
--values ./argo-cd/values.yaml |