-
Notifications
You must be signed in to change notification settings - Fork 189
Expand file tree
/
Copy pathdeploy.yml
More file actions
32 lines (29 loc) · 902 Bytes
/
deploy.yml
File metadata and controls
32 lines (29 loc) · 902 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
# yaml-language-server: $schema=https://json.schemastore.org/github-workflow.json
name: Deploy an app
on:
push:
branches:
- main
jobs:
deploy:
name: Deploy to Slack
runs-on: ubuntu-latest
steps:
- name: Checkout the repo
uses: actions/checkout@v4
with:
persist-credentials: false
- name: Deploy the app
uses: slackapi/slack-github-action/cli@v3.0.1
with:
command: "deploy --app ${{ vars.SLACK_APP_ID }} --force"
token: ${{ secrets.SLACK_SERVICE_TOKEN }}
- name: Post a deployment message
uses: slackapi/slack-github-action@v3.0.1
with:
errors: true
method: chat.postMessage
token: ${{ secrets.SLACK_BOT_TOKEN }}
payload: |
channel: ${{ secrets.SLACK_CHANNEL_ID }}
text: "Deployed to Slack from ${{ github.sha }}"