Sync Oncall to Google Group, Slack Group, and GitHub Team #20
This file contains hidden or 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: Sync Oncall to Google Group and Slack Group | |
| on: | |
| push: | |
| branches: | |
| - main | |
| workflow_dispatch: # Allow manual trigger | |
| jobs: | |
| sync: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v4 | |
| - name: Set up Go | |
| uses: actions/setup-go@v5 | |
| with: | |
| go-version: '1.23' | |
| cache: true | |
| cache-dependency-path: synconcall/go.sum | |
| - name: Build synconcall | |
| run: | | |
| cd synconcall | |
| go build -o synconcall | |
| - name: Sync oncall rotation | |
| env: | |
| GOOGLE_CREDENTIALS: ${{ secrets.GOOGLE_SERVICE_ACCOUNT }} | |
| SLACK_TOKEN: ${{ secrets.SLACK_TOKEN }} | |
| run: | | |
| cd synconcall | |
| ./synconcall --config=../dev.oncall \ | |
| --group=dev-oncall@bytebase.com --admin-user=d@bytebase.com \ | |
| --slack-group=S0AAPDZBNQL \ | |
| --slack-channel=C08CMEAP63T |