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

Adjust test-docker release branch check for Jenkins quirk #26391

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

riftEmber
Copy link
Member

Fix the check in util/cron/test-docker.bash that ensures we're working from the desired release branch when in release mode.

When run in the Jenkins job, this check failed despite having the correct revision checked out. This is because for some reason Jenkins (or the SCM plugin we use, or JJB, not sure) takes the branch you ask to check out, manually dereferences it to the commit it points to, and then checks out that commit by SHA. So HEAD points to a SHA rather than the branch name, and git rev-parse --abbrev-ref HEAD just returns HEAD.

Fixed by comparing the SHA of HEAD against the SHA of the desired branch directly.

[trivial, not reviewed]

Testing:

  • manual run of test-docker.bash in release mode

Signed-off-by: Anna Rift <anna.rift@hpe.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant