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

Allow creating secrets from environment variables and files in CLI #2928

Open
danielgafni opened this issue Mar 5, 2025 · 0 comments
Open

Comments

@danielgafni
Copy link

Currently the only way to set the secret contents is to pass them in CLI args in plain text.

This is:

  • not ideal locally (the secret value is recorded in the shell history unless special precautions are taken)
  • not acceptable in CI/CD pipelines which commonly display the command being run in the logs

I think the modal secret create command should have an interface to load secret values from environment or filesystem instead.

For example:

modal secret create my-secret MY_VALUE=env://MY_VALUE

modal secret create my-secret MY_VALUE=file:///path/to/value

modal secret create --from-file /path/to/secret.json my-secret
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

No branches or pull requests

1 participant