Generate Build Report #584
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Generate Build Report | |
# Uses Python to Generate a build report | |
# and send it to Slack | |
on: | |
workflow_dispatch: | |
schedule: | |
# 6AM UTC is 8AM EET, 7AM CET, 11PM PST. | |
- cron: "0 6 * * *" | |
jobs: | |
build-report: | |
name: Build Report | |
timeout-minutes: 5 | |
runs-on: ubuntu-latest | |
if: github.ref == 'refs/heads/master' | |
steps: | |
- name: Checkout Airbyte | |
uses: actions/checkout@v3 | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install requests slack_sdk pyyaml | |
- name: create and send report | |
run: python ./tools/bin/build_report.py | |
env: | |
SLACK_BUILD_REPORT: ${{ secrets.SLACK_BUILD_REPORT }} | |
- name: Slack Notification - Failure | |
if: failure() | |
uses: rtCamp/action-slack-notify@master | |
env: | |
SLACK_WEBHOOK: ${{ secrets.SLACK_BUILD_REPORT }} | |
SLACK_USERNAME: Build Report | |
SLACK_ICON: https://avatars.slack-edge.com/temp/2020-09-01/1342729352468_209b10acd6ff13a649a1.jpg | |
SLACK_COLOR: ${{ job.status }} | |
SLACK_TITLE: "Failed to create build report" | |
SLACK_MESSAGE: "https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}" | |
MSG_MINIMAL: True |