Skip to content

Commit

Permalink
send discord notification for deployment
Browse files Browse the repository at this point in the history
  • Loading branch information
alphatownsman committed Nov 2, 2023
1 parent d582b4f commit bf986cf
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 0 deletions.
7 changes: 7 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,3 +22,10 @@ jobs:
username: ${{ secrets.SSH_USER }}
key: ${{ secrets.SSH_KEY }}
script: ${{ vars.DEPLOY_SCRIPT }}

- name: Send Discord notification
uses: appleboy/discord-action@master
with:
webhook_id: ${{ secrets.DISCORD_WEBHOOK_ID }}
webhook_token: ${{ secrets.DISCORD_WEBHOOK_TOKEN }}
args: Deployment complete.
21 changes: 21 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,20 @@ jobs:
with:
submodules: 'true'

- name: Check git version
id: version
run: |
echo "neodb=$(git rev-parse --short HEAD)" >> $GITHUB_OUTPUT
cd neodb-takahe
echo "takahe=$(git rev-parse --short HEAD)" >> $GITHUB_OUTPUT
- name: Send Discord notification
uses: appleboy/discord-action@master
with:
webhook_id: ${{ secrets.DISCORD_WEBHOOK_ID }}
webhook_token: ${{ secrets.DISCORD_WEBHOOK_TOKEN }}
args: Building docker image ${{ steps.version.outputs.neodb }}-${{ steps.version.outputs.takahe }}

- name: Set up QEMU
uses: docker/setup-qemu-action@v2

Expand Down Expand Up @@ -52,3 +66,10 @@ jobs:
push: ${{ github.event_name != 'pull_request' }}
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}

- name: Send Discord notification complete
uses: appleboy/discord-action@master
with:
webhook_id: ${{ secrets.DISCORD_WEBHOOK_ID }}
webhook_token: ${{ secrets.DISCORD_WEBHOOK_TOKEN }}
args: Published docker image ${{ steps.version.outputs.neodb }}-${{ steps.version.outputs.takahe }}

0 comments on commit bf986cf

Please sign in to comment.