Skip to content

Commit

Permalink
Remove pre-deploy comment from workflow (can be added later in #202)
Browse files Browse the repository at this point in the history
  • Loading branch information
CodeGat committed Dec 23, 2024
1 parent 155e0de commit 280a8ed
Showing 1 changed file with 11 additions and 24 deletions.
35 changes: 11 additions & 24 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -188,24 +188,6 @@ jobs:
context: ${{ steps.commit-status-args.outputs.context }}
description: ${{ steps.commit-status-args.outputs.description }}

pre-deploy-notifier:
name: Pre Deploy Notifier
needs:
- defaults
runs-on: ubuntu-latest
outputs:
comment-url: ${{ steps.comment.outputs.comment-url }}
steps:
- name: PR Comment Notifier
id: comment
uses: access-nri/actions/.github/actions/comment@main
with:
number: ${{ inputs.pr }}
message: |
:rocket: [Currently Deploying](${{ env.RUN_URL }}) `${{ inputs.model }}` Prerelease as `${{ needs.defaults.outputs.prerelease-version }}` with commit ${{ needs.defaults.outputs.head-sha }}
This comment will be updated with the status of the deployment(s).
deploy:
name: Deploy
needs:
Expand Down Expand Up @@ -262,7 +244,6 @@ jobs:
if: always()
needs:
- defaults # so we can access `inputs.root-sbd` that could have defaulted to `inputs.model`
- pre-deploy-notifier # to get the initial comment URL
- deploy # so we can access deployment information such as versions used, status of deployments, etc.
runs-on: ubuntu-latest
permissions:
Expand Down Expand Up @@ -339,19 +320,25 @@ jobs:
echo "EOF" >> $GITHUB_OUTPUT
- name: Config failure roll up
id: output-config
- name: Config status roll up
id: config-rollup
# Roll up the config status booleans from each of the files, and return the overall result
run: |
# Roll up the config failure booleans from each of the files, and return the overall result
echo "errors=$(jq --slurp 'map(.ci_configuration_check_failure | any)' ${{ env.OUTPUT_ARTIFACT_PATH }}/*)" >> $GITHUB_OUTPUT
- name: Deployment status roll up
id: deployment-rollup
# Roll up the deployment status from each of the files, and return the overall result
run: |
echo "errors=$(jq --slurp 'map(.deployment_result == "success") | all | not' ${{ env.OUTPUT_ARTIFACT_PATH }}/*)" >> $GITHUB_OUTPUT
- name: PR Comment Notifier
id: comment
uses: access-nri/actions/.github/actions/pr-comment@main
with:
comment: |
:rocket: [Deployed](${{ env.RUN_URL }}) `${{ inputs.model }}` as prerelease `${{ needs.defaults.outputs.root-sbd }}/${{ needs.defaults.outputs.prerelease-version }}` with commit ${{ needs.defaults.outputs.head-sha }}
${{ steps.output-config.outputs.errors == 'true' && ':warning:There are issues with the `build-cd` deployment configuration. If this is unexpected, let @ACCESS-NRI/model-release know.' || '' }}
:rocket: [${{ steps.deployment-rollup.outputs.errors == 'true' && 'Attempted to deploy' || 'Deployed' }}](${{ env.RUN_URL }}) `${{ inputs.model }}` as prerelease `${{ needs.defaults.outputs.root-sbd }}/${{ needs.defaults.outputs.prerelease-version }}` with commit ${{ needs.defaults.outputs.head-sha }}
${{ steps.config-rollup.outputs.errors == 'true' && ':warning:There are issues with the `build-cd` deployment configuration. If this is unexpected, let @ACCESS-NRI/model-release know.' || '' }}
${{ steps.matrix-output-parser.outputs.deployments-message }}
Expand Down

0 comments on commit 280a8ed

Please sign in to comment.