Skip to content

Commit

Permalink
update the Send Email and Send Chat Message jobs
Browse files Browse the repository at this point in the history
  • Loading branch information
chamathns committed Jun 16, 2023
1 parent d1fcf3d commit 58da54e
Showing 1 changed file with 10 additions and 6 deletions.
16 changes: 10 additions & 6 deletions .github/workflows/oidc-conformance-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,11 @@ jobs:
echo "Sending Email"
echo "============="
CONFORMANCE_SUITE_URL=https://localhost:8443
python3 ./product-is/oidc-conformance-tests/send_email.py $CONFORMANCE_SUITE_URL $GITHUB_RUN_NUMBER ${{job.status}} ${{github.repository}} ${{github.run_id}} ${{secrets.SENDER_EMAIL}} ${{secrets.PASSWORD}} ${{secrets.RECEIVER_LIST}} ${{github.event.inputs.tag}}
RESOURCE=${{github.event.inputs.download-url}}
if [[ -z "${RESOURCE}" ]]; then
RESOURCE=${{github.event.inputs.tag}}
fi
python3 ./product-is/oidc-conformance-tests/send_email.py $CONFORMANCE_SUITE_URL $GITHUB_RUN_NUMBER ${{job.status}} ${{github.repository}} ${{github.run_id}} ${{secrets.SENDER_EMAIL}} ${{secrets.PASSWORD}} ${{secrets.RECEIVER_LIST}} $RESOURCE
elif [ $SEND_EMAIL == "NO" ]; then
echo "========================================"
echo "Skipped Sending Email"
Expand All @@ -167,20 +171,20 @@ jobs:
if: always()
run: |
INPUT=${{github.event.inputs.send-chat}}
TAG=${{github.event.inputs.tag}}
RESOURCE=${{github.event.inputs.download-url}}
if [[ -z "${RESOURCE}" ]]; then
RESOURCE=${{github.event.inputs.tag}}
fi
if [[ -z "${INPUT}" ]]; then
INPUT="yes"
fi
if [[ -z "${TAG}" ]]; then
TAG=${GITHUB_REF:10}
fi
SEND_CHAT=${INPUT^^}
if [ $SEND_CHAT == "YES" ]; then
echo "==========================="
echo "Sending Google Chat Message"
echo "==========================="
CONFORMANCE_SUITE_URL=https://localhost:8443
python3 ./product-is/oidc-conformance-tests/send_chat.py "$CONFORMANCE_SUITE_URL" "$GITHUB_RUN_NUMBER" "${{job.status}}" "${{github.repository}}" "${{github.run_id}}" "${{secrets.GOOGLE_CHAT_WEBHOOK_OIDC_TEST}}" "$TAG"
python3 ./product-is/oidc-conformance-tests/send_chat.py "$CONFORMANCE_SUITE_URL" "$GITHUB_RUN_NUMBER" "${{job.status}}" "${{github.repository}}" "${{github.run_id}}" "${{secrets.GOOGLE_CHAT_WEBHOOK_OIDC_TEST}}" "$RESOURCE"
elif [ $SEND_CHAT == "NO" ]; then
echo "========================================"
echo "Skipped Sending Google Chat Message"
Expand Down

0 comments on commit 58da54e

Please sign in to comment.