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

Invalid use of DOCKER_SECRET_REDIS_PASS #38

Closed
Tracked by #167
hellkite500 opened this issue Sep 8, 2020 · 1 comment
Closed
Tracked by #167

Invalid use of DOCKER_SECRET_REDIS_PASS #38

hellkite500 opened this issue Sep 8, 2020 · 1 comment
Labels
bug Something isn't working maas MaaS Workstream

Comments

@hellkite500
Copy link
Member

The env variable established in commit 30c48a3 contains the path to the secret file, not the secret itself, but several places in the service code assume that DOCKER_SECRET_REDIS_ is a valid env prefix for the password itself.

Current behavior

Services look for ENV variable DOCKER_SECRET_REDIS_PASS assuming it is the password.

Expected behavior

Either DOCKER_SECRET_REDIS_PASS needs to be re-written, or a different ENV variable needs to be used which is set from the value in the secret file.

The redis service does this approrpiately in the entrypoint.sh

SECRET_FILE="/run/secrets/${DOCKER_SECRET_REDIS_PASS:?}"
REDIS_PASS="$(cat ${SECRET_FILE})"

But the other python based services do not read this secret appropriately, and the function used to parse the env, _get_parsed_or_env_val in the __main__.py checks that DOCKER_SECRET_REDIS_PASS exists, which it does, and uses its value (the path to the secret file in the container file system) as the password it uses to attempt connections with, which fail.

@robertbartel robertbartel added the bug Something isn't working label Jan 4, 2022
@robertbartel robertbartel added this to the 1.0.0 milestone Jan 4, 2022
@robertbartel robertbartel added the maas MaaS Workstream label Jan 26, 2022
@robertbartel robertbartel removed this from the 1.0.0 (AGU FIH) milestone Jun 28, 2022
@aaraney
Copy link
Member

aaraney commented Apr 12, 2024

This is a non-issue any more. See:

@aaraney aaraney closed this as completed Apr 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working maas MaaS Workstream
Projects
None yet
Development

No branches or pull requests

3 participants