Skip to content

Add namespace to secret creation heredoc #492

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

Open
wants to merge 7 commits into
base: master
Choose a base branch
from

Conversation

adamrtalbot
Copy link
Contributor

@adamrtalbot adamrtalbot commented Feb 27, 2025

The heredoc for creating a k8s token was missing a namespace, or at least it didn't match the rest of the docs that focus on the tower-nf namespace. This PR adds it so that it matches up.

Copy link

netlify bot commented Feb 27, 2025

Deploy Preview for seqera-docs ready!

Name Link
🔨 Latest commit 7ffca8f
🔍 Latest deploy log https://app.netlify.com/projects/seqera-docs/deploys/683f631fb0b27400077e8b69
😎 Deploy Preview https://deploy-preview-492--seqera-docs.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@gwright99
Copy link

gwright99 commented Feb 27, 2025

IMO adding an explicit namespace is always a good idea.

If you don't do that, it will either end up in the default namespace (bad) or - if you have customized your kubectl context to default to another namespace - it will go there instead.

IIRC I had this discussion with docs awhile ago on another ticket and there was a deliberate decision to not include it (I dont recall the reason). I'll see if I can dig up the link.

Edit: Here's the link: #133

@adamrtalbot
Copy link
Contributor Author

If you don't do that, it will either end up in the default namespace (bad) or - if you have customized your kubectl context to default to another namespace - it will go there instead.

When I followed the instructions, I did exactly this and it took me a hot minute to work it out.

Copy link

@gwright99 gwright99 left a comment

Choose a reason for hiding this comment

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

As per my comment in the Conversation tab, this issue has been covered before and the resulting structure was a deliberate decision. Sticking to the sidelines and making no comment re: viability of this PR (despite my personal opinions).

@justinegeffen
Copy link
Contributor

Taking @gwright99's comments into account it would probably make sense to update this doc to better reflect the changes we made to the enterprise content last year. @adamrtalbot, would that work? The change is here: https://github.com/seqeralabs/docs/pull/133/files.

@justinegeffen justinegeffen requested a review from gwright99 March 16, 2025 20:59
@@ -44,6 +44,7 @@ This guide applies a Kubernetes manifest that creates a service account named `t
kind: Secret
metadata:
name: tower-launcher-token
namespace: tower-nf

Choose a reason for hiding this comment

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

The next paragraph down also could do with adding the namespace explicitly to the kuebctl command to verify that token was created successfully.

kubectl -n tower-nf describe secrets/tower-launcher-token

Choose a reason for hiding this comment

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

Also slightly further down - also mossing a ns

kubectl describe secret <SERVICE-ACCOUNT-TOKEN-NAME> | grep -E '^token' | cut -f2 -d':' | tr -d '\t '

1. Confirm that Kubernetes created the persistent API token secret:

```bash
kubectl describe secrets/tower-launcher-token
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
kubectl describe secrets/tower-launcher-token
kubectl -n tower-nf describe secrets/tower-launcher-token

- To authenticate using a Kubernetes service account, enter your **Service account token**. Obtain the token with the following command:

```bash
kubectl describe secret <SERVICE-ACCOUNT-TOKEN-NAME> | grep -E '^token' | cut -f2 -d':' | tr -d '\t '
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
kubectl describe secret <SERVICE-ACCOUNT-TOKEN-NAME> | grep -E '^token' | cut -f2 -d':' | tr -d '\t '
kubectl -n tower-nf describe secret <SERVICE-ACCOUNT-TOKEN-NAME> | grep -E '^token' | cut -f2 -d':' | tr -d '\t '

@justinegeffen
Copy link
Contributor

Thanks for this, @adamrtalbot! I've implemented the suggested changes. Please could you give them a review and then I think we're good to merge. :)

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.

4 participants