-
Notifications
You must be signed in to change notification settings - Fork 8
Check before downloading gem #136
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
base: main
Are you sure you want to change the base?
Conversation
@wildmaples this implementation is a bit unexpected. I'm wondering if there's a way for the image build step itself to block on the gem publish. Do you know where the gem publishing is happening? If it's manual, we could extract this logic to a dedicated step, so it doesn't live inside the Dockerfile. |
Dockerfile
Outdated
COPY .buildkite/docker/bootstrap /tmp/bootstrap | ||
ARG version | ||
RUN gem update --system --no-document && \ | ||
if [ -z "$version" ]; then \ | ||
gem install buildkite-builder; \ | ||
else \ | ||
gem install buildkite-builder -v "$version"; \ | ||
fi | ||
RUN /tmp/bootstrap |
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.
Move ARG
before COPY
. Change to:
RUN /tmp/boostrap && rm -f /tmp/bootstrap
The gem publishing is happening in this script. The image build step to block on gem publish was my initial consideration but I opted for the looped retrying so we won't have to take the action to unblock twice in order to publish. |
Wait for rubygems to make new version available before running docker push.
Got a successful push: https://hub.docker.com/layers/gusto/buildkite-builder/4.18.0/images/sha256-e65226fd370c7a60b14b195d5c1ba494cf1a341a2bec18bf53ac2aab03915bf8