Skip to content

nestoca/joy-generator

Repository files navigation

joy-generator

ArgoCD plugin for expanding joy releases for the ArgoCD ApplicationSet Controller.

Dev Setup

go install github.com/matryer/moq@latest

How-to roll-out and test updates

  1. Update this repo and merge to master (triggering a build & /release)
    1. Note the new release version# from https://github.com/nestoca/joy-generator/releases
    2. Ensure the same version is present here
  2. Apply the newly released version in infra's component ArgoCD.configureJoyGenerator()'s devVersion here
    1. do pu main preview-markdown on infra/pulumi/platform as part of your PR/roll-out & merge, as normal
  3. Test the new version
    1. ℹ️ devVersion will be deployed to environments that contain dev in their name, version to all other envs
    2. Update the catalog (e.g. an env-var in canary) & merge to master
    3. Verify that the env-var is present in ArgoCD's Live Manifest under dev-canary > rollout > latest rs(ReplicaSet) > pod
  4. Apply the newly released version in infra's component ArgoCD.configureJoyGenerator()'s version here
    1. do pu main preview-markdown on infra/pulumi/platform as part of your PR/roll-out & merge, as normal
  5. VICTORY! 💪

Data Flow

Argo CD's ApplicationSet controller will query joy-generator on Webhooks or schedule. The latter returns a full list of parameters for each application in the catalog. The ApplicationSet controller will then create or update the Application resources in the cluster. See Argo CD - Generators Plugin for more information.

sequenceDiagram
    participant user as User
    participant gh as GitHub
    participant a as ArgoCD
    participant jg as Joy Generator
    participant k8s as Kubernetes

    user->>gh: Merge a PR
    gh->>a: Webhook
    a->>jg: Get list parameter values to use as a template
    jg->>gh: Pull latest commit of master
    jg->>a: Generate list of parameters for each applications in the catalog
    a->>k8s: Create or update ApplicationSet
    a->>k8s: Create or update Application
    k8s->>a: ApplicationSet created or updated
    a->>k8s: Sync Applications (if needed)
    k8s->>a: Applications synced

Loading

About

No description or website provided.

Topics

Resources

Stars

Watchers

Forks

Packages

 
 
 

Contributors 9