Skip to content

feat(argocd): secure password input and optional deploy-dc-config params#439

Merged
Jcing95 merged 12 commits into
mainfrom
add-install-ago-secrets
May 29, 2026
Merged

feat(argocd): secure password input and optional deploy-dc-config params#439
Jcing95 merged 12 commits into
mainfrom
add-install-ago-secrets

Conversation

@Jcing95
Copy link
Copy Markdown
Contributor

@Jcing95 Jcing95 commented May 22, 2026

Summary

  • OCI registry password is now read from OMS_REGISTRY_PASSWORD env var or prompted
    interactively (removes --registry-password flag)
  • Git repo password is now read from OMS_GIT_PASSWORD env var; git repo credential
    is skipped when not set (removes --git-password flag)
  • --dc-id is now optional: local cluster secret is skipped when not provided
  • OCI registry URL is now configurable via --registry-url flag (defaults to
    ghcr.io/codesphere-cloud/charts)
  • Removes the standalone argocd-repo-secret subcommand (functionality covered by
    --deploy-dc-config)
  • Wraps underlying error in NewArgoCD failure path for better debugging
  • Adds OCI password validation before applying the Helm registry secret

Usage

# Install ArgoCD chart only
oms beta install argocd

# Install chart + apply Codesphere resources (prompts for OCI password)
oms beta install argocd --deploy-dc-config

# Full install with all resources
OMS_REGISTRY_PASSWORD=token OMS_GIT_PASSWORD=git-token oms beta install argocd --deploy-dc-config --dc-id 0

# Use a custom/mirrored OCI registry
OMS_REGISTRY_PASSWORD=token oms beta install argocd --deploy-dc-config --registry-url my-registry.example.com/charts

Breaking Changes

  • --registry-password flag removed (use OMS_REGISTRY_PASSWORD env var instead)
  • --git-password flag removed (use OMS_GIT_PASSWORD env var instead)
  • oms beta install argocd-repo-secret subcommand removed

@Jcing95 Jcing95 self-assigned this May 22, 2026
@Jcing95 Jcing95 requested a review from Copilot May 22, 2026 16:50
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds a new oms beta install argocd-repo-secret command to create/update ArgoCD repository secrets (Helm OCI or Git), backed by a rendered Kubernetes Secret manifest and applied via the existing Kubernetes apply helpers.

Changes:

  • Introduces a generic ArgoCD repo Secret template and an internal/installer helper to render/apply it.
  • Adds a new Cobra subcommand under oms beta install to collect flags + resolve password and apply the secret.
  • Adds Ginkgo tests and user-facing docs for the new command.

Reviewed changes

Copilot reviewed 7 out of 7 changed files in this pull request and generated 6 comments.

Show a summary per file
File Description
internal/installer/manifests/argocd/repo-secret.yaml.tpl New generic ArgoCD repository Secret YAML template (parameterized).
internal/installer/argocd_repo_secret.go New installer that renders the template and applies the Secret to the cluster.
internal/installer/argocd_repo_secret_test.go Tests for creating/updating the repo Secret via a fake Kubernetes client.
docs/oms_beta_install.md Adds the new subcommand to the beta install docs index.
docs/oms_beta_install_argocd-repo-secret.md New documentation page for the command usage/options/examples.
cli/cmd/beta_install.go Wires the new subcommand into oms beta install.
cli/cmd/argocd_repo_secret.go New Cobra command implementation and password resolution logic.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread internal/installer/manifests/argocd/repo-secret.yaml.tpl Outdated
Comment thread cli/cmd/argocd_repo_secret.go Outdated
Comment thread cli/cmd/argocd_repo_secret.go Outdated
Comment thread docs/oms_beta_install_argocd-repo-secret.md Outdated
Comment thread internal/installer/argocd_repo_secret_test.go Outdated
Comment thread internal/installer/argocd_repo_secret.go Outdated
@Jcing95 Jcing95 changed the title feat(argocd): add image pull secrets via oms beta install argocd-repo-secret feat(argocd): add command to install Codesphere Helm repo secret May 26, 2026
@Jcing95 Jcing95 requested a review from Copilot May 26, 2026 07:35
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 7 out of 7 changed files in this pull request and generated 3 comments.

Comment thread cli/cmd/argocd_repo_secret.go Outdated
Comment thread internal/installer/argocd_repo_secret.go Outdated
Comment thread docs/oms_beta_install_argocd-repo-secret.md Outdated
@Jcing95 Jcing95 changed the title feat(argocd): add command to install Codesphere Helm repo secret feat(argocd): secure password input and optional deploy-dc-config params May 26, 2026
@Jcing95 Jcing95 force-pushed the add-install-ago-secrets branch from 9bb9f6e to 0c87812 Compare May 26, 2026 12:47
@Jcing95 Jcing95 requested a review from Copilot May 26, 2026 12:48
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.

Comment thread cli/cmd/argocd.go Outdated
Comment thread internal/installer/argocd_resources.go
@Jcing95 Jcing95 requested a review from schrodit May 26, 2026 12:53
Comment thread internal/installer/argocd_resources.go Outdated
Comment thread internal/installer/argocd_resources.go
@Jcing95 Jcing95 requested a review from schrodit May 27, 2026 05:25
Copy link
Copy Markdown
Member

@schrodit schrodit left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

mostly fine just some clarification missing

Comment thread cli/cmd/argocd.go
Comment thread internal/installer/argocd_resources.go
Comment thread internal/installer/argocd_resources.go
Copy link
Copy Markdown
Contributor

@bachgg bachgg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

General logic change looks good to me

Jcing95 and others added 10 commits May 28, 2026 15:55
Signed-off-by: Jcing95 <23337729+Jcing95@users.noreply.github.com>
Hardcode all other values for the codesphere-helm-repo secret.
The repo URL defaults to ghcr.io/codesphere-cloud/charts but can be
overridden for mirrors. Username defaults to CodesphereBot.
Signed-off-by: Jcing95 <23337729+Jcing95@users.noreply.github.com>
@Jcing95 Jcing95 force-pushed the add-install-ago-secrets branch from 206330b to 88cf040 Compare May 28, 2026 14:04
@Jcing95 Jcing95 merged commit aa005bd into main May 29, 2026
6 checks passed
@Jcing95 Jcing95 deleted the add-install-ago-secrets branch May 29, 2026 11:59
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.

5 participants