Improve step error conditions

Signed-off-by: Benoit Donneaux <benoit@leastauthority.com>
This commit is contained in:
bEn 2024-05-24 12:53:27 +02:00
parent d2c7588767
commit daf2ed5190
1 changed files with 1 additions and 9 deletions

View File

@ -52,7 +52,6 @@ jobs:
fi
docker-compose run --rm -v "${JOB_CONTAINER_NAME}:/site" -w /site \
jekyll build --verbose
continue-on-error: true
- name: Deploy Jekyll site
id: deploy_site
run: |
@ -75,10 +74,9 @@ jobs:
rsync -halvi --delete \
-e "ssh -a -x -o StrictHostKeyChecking=no" \
./_site/ "${WEB_USER}@${WEB_DOMAIN}:${WEB_ROOT}${WEB_CONTEXT}"
continue-on-error: true
- name: Comment pull request
id: comment_pull_request
if: gitea.event_name == 'pull_request'
if: ${{ always() && gitea.event_name == 'pull_request' }}
uses: exercism/pr-commenter-action@v1.5.1
with:
template-variables: |
@ -96,9 +94,3 @@ jobs:
"gitRunAttempt": "${{ gitea.run_attempt }}"
}
config-file: ".gitea/pr-commenter.yml"
- name: Fail on error
id: fail-on-error
if: |
steps.build_site.outcome != 'success'
|| steps.deploy_site.outcome != 'success'
run: exit 1