-
Notifications
You must be signed in to change notification settings - Fork 3
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
Check that file exists before attempting to move it #368
Conversation
Packer is not preinstalled on the ubuntu-24.04 runner image, for example, so the previous code will result in an error there.
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.
👍
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.
LGTM ✔
@@ -115,7 +115,10 @@ jobs: | |||
"https://releases.hashicorp.com/packer/${PACKER_VERSION}/${PACKER_ZIP}" | |||
sudo unzip -d /opt/packer \ | |||
${{ env.CURL_CACHE_DIR }}/"${PACKER_ZIP}" | |||
sudo mv /usr/local/bin/packer /usr/local/bin/packer-default | |||
if [ -e /usr/local/bin/packer ] |
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.
Would you please backport this to cisagov/skeleton-generic? I believe this will start to be a problem as ubuntu-latest
is starting to use ubuntu-24.04
with a GA this month based on actions/runner-images#9691 (comment).
@mcdonnnj found a |
This can be found in cisagov/skeleton-generic#187. |
🗣 Description
This pull request modifies the GitHub workflows to verify that
/usr/local/bin/packer
exists before attempting tomv
it.💭 Motivation and context
Packer is not preinstalled on the
ubuntu-24.04
runner image, for example, so the previous code will result in an error there.🧪 Testing
This change was tested as part of cisagov/freeipa-server-packer#133.
✅ Pre-approval checklist