Skip to content

Conversation

@JesperTerkelsen
Copy link
Member

Summary

FEATURE: Add ArgoCD deployment monitoring support to deploy-generic workflow.

Context

Currently, only deploy-kotlin.yml and deploy-generic-v2.yml have ArgoCD monitoring support. This PR brings the same capabilities to deploy-generic.yml so all repositories can benefit from:

  • Real-time deployment monitoring
  • Accurate deployment timing metrics
  • Direct links to ArgoCD UI
  • Automatic supersede detection
  • Fast revision detection with auto-refresh

Changes

deploy-generic.yml

New input:

argocd-server:
  required: false
  type: string
  description: 'ArgoCD server URL (e.g., argocd.monta.app) for deployment monitoring'

New secret:

ARGOCD_TOKEN:
  required: false
  description: 'ArgoCD authentication token (required if auto-sync is enabled in config.yaml)'

New outputs:

deployment-start-time:
  description: 'ISO 8601 timestamp when ArgoCD started the sync (only if auto-sync enabled)'
  value: ${{ jobs.deploy.outputs.deployment-start-time }}
deployment-end-time:
  description: 'ISO 8601 timestamp when deployment became healthy (only if auto-sync enabled)'
  value: ${{ jobs.deploy.outputs.deployment-end-time }}
deployment-url:
  description: 'Direct URL to the application in ArgoCD UI (only if auto-sync enabled)'
  value: ${{ jobs.deploy.outputs.deployment-url }}

Pass-through to component-deploy.yml:

with:
  argocd-server: ${{ inputs.argocd-server }}
secrets:
  ARGOCD_TOKEN: ${{ secrets.ARGOCD_TOKEN }}

How to Enable

Repositories using deploy-generic can enable ArgoCD monitoring by:

  1. Add argocd-server input:
uses: monta-app/github-workflows/.github/workflows/deploy-generic.yml@main
with:
  argocd-server: argocd.monta.app  # or argocd.staging.monta.app
  # ... other inputs
secrets:
  ARGOCD_TOKEN: ${{ secrets.ARGOCD_TOKEN }}
  # ... other secrets
  1. Configure autoSync in config.yaml:
# apps/{service}/stage/cluster/config.yaml
autoSync:
  prune: true
  selfHeal: true
  1. Provide ARGOCD_TOKEN secret (repository or organization level)

Features

All ArgoCD monitoring features are now available:

Real-time monitoring - Wait for sync and health status
Deployment timing - Accurate start/end timestamps
ArgoCD UI links - Direct links in outputs
Supersede detection - Detects when deployments are bundled
Fast refresh - Immediate revision detection (5-10s vs 30+ seconds)
ComparisonError recovery - Auto hard-refresh on cache corruption
Bundled deployments - Succeeds with warning when changes are bundled

Workflow Coverage

After this PR:

  • deploy-kotlin.yml - Has ArgoCD support
  • deploy-generic.yml - NEW - Has ArgoCD support
  • deploy-generic-v2.yml - Has ArgoCD support
  • component-deploy.yml - Low-level with ArgoCD support
  • component-deploy-v2.yml - Low-level with ArgoCD support

All deploy workflows now support ArgoCD monitoring!

Testing

After merge, repositories can opt-in to ArgoCD monitoring by providing the argocd-server input and ARGOCD_TOKEN secret.

🤖 Generated with Claude Code

…flow

Adds ArgoCD deployment monitoring to deploy-generic.yml to match the
capabilities of deploy-generic-v2.yml and deploy-kotlin.yml.

Changes:
- Add argocd-server input parameter
- Add ARGOCD_TOKEN secret
- Add deployment timing outputs (start-time, end-time, deployment-url)
- Pass ArgoCD parameters to component-deploy.yml

Repositories using deploy-generic can now enable ArgoCD monitoring by:
1. Adding argocd-server input (e.g., argocd.monta.app)
2. Providing ARGOCD_TOKEN secret
3. Configuring autoSync in config.yaml

Benefits:
- Real-time deployment monitoring
- Accurate deployment timing metrics
- Direct links to ArgoCD UI
- Automatic supersede detection
- Fast revision detection with auto-refresh
@JesperTerkelsen JesperTerkelsen merged commit 6cdd40c into main Jan 15, 2026
1 check passed
@JesperTerkelsen JesperTerkelsen deleted the feat/add-argocd-support-to-deploy-generic branch January 15, 2026 19:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants