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

Feed cloudops-infra env into tests/test_init.py #628

Open
ahal opened this issue Jan 23, 2023 · 0 comments
Open

Feed cloudops-infra env into tests/test_init.py #628

ahal opened this issue Jan 23, 2023 · 0 comments

Comments

@ahal
Copy link
Contributor

ahal commented Jan 23, 2023

I recently added a test that runs the docker.d/init.sh script. The problem is that it relies on a ton of environment variables that are populated from cloudops-infra. To get around this, I basically just manually created a giant context dict containing dummy values for everything.

Ben had the idea of trying to fetch these directly (would need a Github API token) and using the actual variables fetched from the cloudops-infra repo. Not only would this make manual maintenance less of a burden, but it would turn test_init.sh into an integration test that covers parts of the deploy pipeline with cloudops-infra as well.

Note that the values come from SOPS, so we'd obviously still need dummy values for the keys.. But these could be autogenerated for any keys we detect.

@ahal ahal changed the title Populate cloudops-infra env into tests/test_init.py Feed cloudops-infra env into tests/test_init.py Jan 23, 2023
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