Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: playbook to update the letsencrypt certificate on the ocp cluster #366

Open
wants to merge 4 commits into
base: main
Choose a base branch
from

Conversation

jacobdotcosta
Copy link
Member

Closes #365

@jacobdotcosta jacobdotcosta added the enhancement New feature or request label Mar 11, 2024
@jacobdotcosta jacobdotcosta self-assigned this Mar 11, 2024

[.fuchsia]#string# / [.red]#required#

a| Name of the site that will be used to fetch the certificates from.
Copy link
Member

Choose a reason for hiding this comment

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

This wording is a bit confusing: "Name of the site". What is a site ? Is it a domain name, something else ?

Copy link
Member Author

Choose a reason for hiding this comment

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

That's a tough one, it's the name of the prefix given to the TLS secret which coincides with the OCP cluster name.

$ kc --namespace snowdrop-site get secret
...
qshift-snowdrop-dev-tls         kubernetes.io/tls   2      96d
www-snowdrop-dev-tls            kubernetes.io/tls   2      68d

Copy link
Member

Choose a reason for hiding this comment

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

Ok. That corresponds to a TLS secret which has been created part of a namespace.

Historically the certificate's related stuffs have been created under 2 namespaces using an ansible playbook: snowdrop-site and halkyon-site.

I'm not against the fact to keep this convention and that we create additional secrets, certificates request under the namespace which match a DNS domain (example: snowdrop-site => snowdrop.dev) BUT that should be clear to the user and that they know which namespace they should use. As we only manage one domain name, we could set as default snowdrop-site to avoid issues. WDYT ? @jacobdotcosta

Comment on lines 222 to 223
-e source_kubeconfig=${HOME}/.kube/snowdrop-rhosp-snowdrop-k8s-config \ <1>
-e target_kubeconfig=${HOME}/.kube/rh-ocp-qshift-drp2b-config \ <2>
Copy link
Member

Choose a reason for hiding this comment

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

Is it documented how users can fetch such config files ?

Copy link
Member Author

Choose a reason for hiding this comment

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

Updated the documentation.

Copy link
Member

Choose a reason for hiding this comment

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

Instead of asking to the user to get/copy the kubeconfig file locally, why don't you get it using a password command ?

-e source_kubeconfig=${HOME}/.kube/snowdrop-rhosp-snowdrop-k8s-config

to

-e source_kubeconfig=$(pass ....) 

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Find a way to grab the new certificate generated by Lets'encrypt to update our cluster (or a cluster)
2 participants