sourcegraph/.github/workflows/progress.yml
Dave Try fec0f4a5c2
progress_bot: use gcloud auth action (#44088)
* try new version of action

* git config

* git config in the docker image

* testing git config in image

* add comment

* new tag

* auth with gcloud action

* remove envvar
2022-11-08 10:25:27 -07:00

42 lines
1.4 KiB
YAML

name: Progress bot
on:
workflow_dispatch:
inputs:
since:
description: 'Time period to report'
required: false
default: '24h'
dry:
description: 'Only output message that would be sent to Slack'
required: false
default: 'false'
channel:
description: 'Slack channel to send message to'
required: false
default: 'progress'
schedule:
- cron: "0 0 * * *" # Every day 00:00 UTC (4pm PST)
jobs:
report-to-slack:
if: github.repository == 'sourcegraph/sourcegraph'
runs-on: ubuntu-latest
name: Report the last 24h of CHANGELOG to the progress channel
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 1000
- name: Configure gcloud
uses: google-github-actions/auth@v0
with:
credentials_json: ${{ secrets.PROGRESS_BOT_GCP_ACCOUNT_KEY }}
service_account: 'progress-bot@sourcegraph-dev.iam.gserviceaccount.com'
- name: Report to Slack
uses: docker://sourcegraph/progress-bot:latest@sha256:adbce46dde34527bcb27027a552c76cc0622683297dd935111fe6e1067c53efa
env:
SINCE: ${{ github.event.inputs.since || '24h' }}
DRY: ${{ github.event.inputs.dry || 'false' }}
CHANNEL: ${{ github.event.inputs.channel || 'progress' }}
SLACK_API_TOKEN: ${{ secrets.PROGRESS_BOT_SLACK_API_TOKEN }}