-
Notifications
You must be signed in to change notification settings - Fork 247
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
feat(ci): Build container images without python deps #2572
base: master
Are you sure you want to change the base?
Conversation
This change allows building the container images without the python dependencies that are getting harder to get by. Signed-off-by: Antoni Segura Puimedon <[email protected]>
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: celebdor The full list of commands accepted by this bot can be found here.
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
@celebdor: The following test failed, say
Full PR test history. Your PR dashboard. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. I understand the commands that are listed here. |
SOURCE_GIT_TAG := $(shell export HOME=$(HOME); python3 -m ensurepip >&2; python3 -mpip --no-cache install --user gitpython pyyaml >&2; hack/version2.py) | ||
# 0.0.x-y if it is an `UnknownBranch`. However, the {commitcount} and {sha} | ||
# should still be accurate. | ||
SOURCE_GIT_TAG := $(shell hack/version2.sh) |
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.
Love this. It was super annoying waiting for pip every time the Makefile loaded up.
However, this may have been the only thing ensuring that pyyaml
was installed when running generate-saas-template.py. I'm going to look into porting that to bash/yq as well, but in the meantime, can we add the ensurepip
and pyyaml
business inside that rule? (At least then it will only run when that rule is invoked.)
function prefix_from_branch() { | ||
declare -r branch_name="$1" | ||
|
||
if [[ "$branch_name" =~ ^([^/]+/)?mce-([[:digit:]]+.[[:digit:]]+) ]]; then |
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.
I've asked and ACM/MCE don't seem to be using bundle-gen anymore. Given that, and the fact that we don't build OperatorHub bundles for MCE branches anymore, we should be able to eliminate this condition.
This change allows building the container images without the python dependencies that are getting harder to get by.
It keeps the pre-existing version2.py so that it can be imported from the python bundle generation code