Skip to content

Add secrets file handling #47

@slominskir

Description

@slominskir

It would be nice if this lib provided a function to grab secrets (API Keys) from a file. This would be slightly better than having apps do their own thing, usually relying on environment variables. File access is slightly better than environment variables because it doesn't require an app server restart to update. Shared servers with heavy usage are a bad combination when asking to restart because an API key expired. Unfortunately, file system secret storage is more complex and probably requires an extra environment variable, DB Setting, or classpath configuration to point to the secrets file. Putting the API keys in the DB Settings table would be easy, and avoid requiring restarts for changes, but is less secure as it's more accessible (the DB Settings table solved the change config without restart problem for non-secrets). Plus, in dev and test container environments, it's nice if the file system or env can be used to find secrets such that the test/dev container database can be shared. Local file with appropriate file permissions is roughly equally secure vs ENV, and envs are often bootstrapped from a file anyways.

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions