Repository navigation
docs: move Tailscale API token guide from issue #15 to wiki #24
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
Merged
Merged
Changes from all commits
Commits
Show all changes
3 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,28 @@ | ||
| # Tailscale API token | ||
|
|
||
| You can create the token here: | ||
| [https://login.tailscale.com/admin/settings/keys](https://login.tailscale.com/admin/settings/keys). | ||
|
|
||
| Under **API access tokens**, click **Generate access token\u2026**. | ||
| 90 days is the maximum, and the description can be anything, | ||
| e.g. `born2root baas`. | ||
|
|
||
| For a credential that never expires, use an OAuth client instead: | ||
| [https://login.tailscale.com/admin/settings/oauth](https://login.tailscale.com/admin/settings/oauth), | ||
| with scopes `auth_keys`, `dns` and `devices`. | ||
|
|
||
| **Do not paste the token in chat or issues.** | ||
| Anything sent in conversation history stays there. | ||
| Write it straight into the secrets file instead | ||
| (only needs to be done once): | ||
|
|
||
| ```bash | ||
| nano ~/.config/born2root/b2b-secrets | ||
| ``` | ||
|
|
||
| Fill in the empty `TS_API_TOKEN=` line, or add one if | ||
| it's missing: | ||
|
|
||
| ```text | ||
| TS_API_TOKEN=tskey-api-... | ||
| ``` | ||
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Secure the file before entering the token.
If the file does not exist,
nanocan create it with permissions derived from the umask. With a permissive umask and searchable parent directories, other local users can read the token.secret_getalso rejects modes other than600or400. Instruct readers to create or secure the file before editing it. (raw.githubusercontent.com)Script executed:
rg -n 'B2B_SECRETS|b2b-secrets' setupRepository: Univers42/born2root
Length of output: 2938
Script executed:
Repository: Univers42/born2root
Length of output: 17372
Script executed:
Repository: Univers42/born2root
Length of output: 10924
Use the selected secrets-file path.
If
B2B_SECRETS, the profile, or an existing repository-root.b2b-secretsselects another file, the scripts do not read the token added to the default file. API operations can then fail or fall back to manual steps.Tell readers to edit the selected secrets file. Identify the shown path as the default.