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

Update docs with correct secret file paths for destination-specific secrets #106

Merged
merged 1 commit into from
Sep 27, 2024

Conversation

visini
Copy link
Contributor

@visini visini commented Sep 27, 2024

Destination-specific secret files are actually looked up with a dot prefix (e.g., secrets.production) instead of a hyphen prefix (e.g., secrets-production, as currently pointed out in the docs), according to https://github.com/basecamp/kamal/blob/8c32e6af07356031ffbad2e8eb60169904bc5e52/lib/kamal/secrets.rb#L10

@@ -22,7 +22,7 @@ env:

Kamal uses dotenv to automatically load environment variables set in the `.kamal/secrets` file.

If you are using destinations, secrets will instead be read from `.kamal/secrets-<DESTINATION>` if it exists.
If you are using destinations, secrets will instead be read from `.kamal/secrets.<DESTINATION>` if it exists.

Common secrets across all destinations can be set in `.kamal/secrets-common`.
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Maybe after all secrets-<DESTINATION> would more sense, in order to be consistent with secrets-common?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Copy link
Contributor

Choose a reason for hiding this comment

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

Thanks @visini! The docs are indeed wrong, secrets-common uses a dash so that you could have a destination called common.

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.

2 participants