Skip to content

✨ Support for secrets in one environment variable #51

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
smoliji opened this issue Jan 10, 2025 · 0 comments
Open

✨ Support for secrets in one environment variable #51

smoliji opened this issue Jan 10, 2025 · 0 comments
Labels
enhancement New feature or request

Comments

@smoliji
Copy link
Contributor

smoliji commented Jan 10, 2025

Is your feature request related to a problem?

No.

What feature would you like to see?

I'd like to use CFG_JSON_PATH for both file path and secrets contents directly and interchangeably.

CFG_JSON_PATH=/path/to/file

or

CFG_JSON_PATH=the_secrets_themselves

What alternatives have you considered?

None.

Additional context

Coming from Google Cloud environment, it is common for a configuration variables for secrets to contain one of either a) path to a file where secret is stored, b) the secret it self.

Configuru already has A, I'd like to see B too.

Cloud Run secrets can be injected to env var directly.

Google lib google-auth-library and its GOOGLE_APPLICATION_CREDENTIALS supports the same pattern.

Benefits:

  • One can run app with latest secrets without storing them locally, e.g. with CFG_JSON_PATH=$(gcloud secrets versions access latest --project=boxnow-development --secret=boxnow_customer_app_development_dotenv-api) npm start
  • Configuru-powered apps would be 100% compatible with secrets injection on GCP
@smoliji smoliji added the enhancement New feature or request label Jan 10, 2025
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

No branches or pull requests

1 participant