Skip to content

argocd-agentctl create Agent from existing TLS secret #622

@gnunn1

Description

@gnunn1

Is your feature request related to a problem? Please describe.

When using cert-manager instead of argocd-agentctl to manage PKI it's a pain to formulate the required cluster secret manually since you need to extract the CA, TLS cert and TLS key from the generated Certificate secret and then create the cluster secret using the right JSON format for config.

See the steps in the cert-manager PR here: https://github.com/argoproj-labs/argocd-agent/pull/620/files#diff-9232676f0184124a604022337fed7719340a566c7806114a08fd1aa7750c7d18R194

Describe the solution you'd like

The argocd-agentctl should have a create-from-tls command to create the cluster secret based on an existing TLS secret. Maybe something like:

argocd-agentctl pki cluster-secret <tls-secret-name> --principal-context <context> --principal-context-namespace <namespace> 

Describe alternatives you've considered

  • Creating cluster secret manually which is a multi-step process.
  • Using ESO's ability to template secrets. Basically have an ESO Kubernetes SecretStore to read the TLS secret and then create an ExternalSecret that templates out the cluster secret correctly. It has more moving parts and requires ESO be installed.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions