Merge pull request #5552 from nonsense/nonsense/circle-halt-step-gracefully

circleci: halt step gracefully
This commit is contained in:
Łukasz Magiera 2021-02-09 13:49:20 +01:00 committed by GitHub
commit 55007a0c4e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -533,6 +533,14 @@ jobs:
description: A comma-separated string containing docker image tags to build and push (default = latest)
steps:
- run:
name: Confirm that environment variables are set
command: |
if [ -z "$AWS_ACCESS_KEY_ID" ]; then
echo "No AWS_ACCESS_KEY_ID is set. Skipping build-and-push job ..."
circleci-agent step halt
fi
- aws-cli/setup:
profile-name: <<parameters.profile-name>>
aws-access-key-id: <<parameters.aws-access-key-id>>