-
Notifications
You must be signed in to change notification settings - Fork 23
CI: Avoid leaking credentials in container image builds #937
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
Conversation
markgoddard
commented
Feb 13, 2024
- Revert "Don't verify Apt repo CA initially when using HTTPS in container build"
- Revert "Add package repository credentials to container image build"
- Add Ansible Galaxy roles and collections to .gitignore
- Add a playbook to deploy an authenticating Pulp proxy
- Use authenticating Pulp proxy during container image builds
…ner build" This reverts commit f8947a9. This approach is not secure and leaves credentials in images.
This reverts commit 05e1995. This approach is not secure and leaves credentials in images.
There is currently no practical, secure way to provide credentials for accessing Ark's authenticated package repositories from within a Kolla build. Docker provides build secrets, but these must be explicitly requested for each RUN statement, making them challenging to use in Kolla. This change adds a playbook that deploys an Nginx container that runs as a reverse proxy, injecting an HTTP basic authentication header into requests. Because this proxy bypasses Pulp's authentication, it must not be exposed to any untrusted environment. [1] https://docs.docker.com/build/building/secrets/
250fb76
to
bd03772
Compare
This change uses the authenticating Pulp proxy added in 6320be9 to provide container image builds access to Ark's authenticated package repositories without injecting the credentials into the built images or their metadata.
bd03772
to
9f940b7
Compare
Running the hello-world container from Dockerhub at the beginning of workflows can cause us to hit rate limits. Switch to a simple docker ps.
AIO jobs are failing with an issue seen upstream:
|
- name: Install Docker Python SDK | ||
run: | | ||
pip install --user docker | ||
sudo pip install docker |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sudo pip
😬
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not ideal, but necessary with connection=local and ansible_python_interpreter=/usr/bin/python3.