Skip to content

Commit

Permalink
make the exit code an output since GHA didn't see it 🤷
Browse files Browse the repository at this point in the history
  • Loading branch information
dev-dull committed Nov 21, 2024
1 parent 86bfd21 commit 65ec02c
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/docker-build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -85,15 +85,15 @@ jobs:
curl -X LOCK -sS http://localhost:2442/lock?env=InT
cd .github/build_tests
terraform apply --auto-approve
exit $?
echo "exit_code=$?" >> $GITHUB_OUTPUT
- name: Verify Command Failed Successfully
run: |
if [ "${{ steps.prelock_InT.outcome }}" != "success" ]; then
if [ "${{ steps.prelock_InT.exit_code }}" -eq 1 ]; then
if [ "${{ steps.prelock_InT.outputs.exit_code }}" -eq 1 ]; then
echo "Environment lock was successful"
curl -X UNLOCK -sS http://localhost:2442/unlock?env=InT
else
echo "Step failed with unexpected exit code ${{ steps.prelock_InT.exit_code }}."
echo "Step failed with unexpected exit code ${{ steps.prelock_InT.outputs.exit_code }}."
exit 1
fi
else
Expand Down

0 comments on commit 65ec02c

Please sign in to comment.