Skip to content

ref path

ref path #248

Workflow file for this run

name: Fly Deploy
on:
push:
branches:
- main
jobs:
deploy:
name: Deploy app
runs-on: ubuntu-latest
env:
FLY_API_TOKEN: ${{ secrets.FLY_API_TOKEN }}
outputs:
gitrev: ${{ steps.gitparse.outputs.rev }}
steps:
- uses: actions/checkout@v3
- uses: superfly/flyctl-actions/setup-flyctl@master
- run: flyctl deploy --remote-only
- id: gitparse
run: echo "rev=`git rev-parse --short ${{ github.sha }}`" >> $GITHUB_OUTPUT
notify:
needs: [deploy]
name: Notify slack
runs-on: ubuntu-latest
env:
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
SLACK_WEBHOOK_TYPE: INCOMING_WEBHOOK
steps:
- uses: slackapi/[email protected]
with:
payload: |
{
"blocks": [
{
"type": "section",
"text": {
"type": "mrkdwn",
"text": "new version <${{ github.event.head_commit.url }}|${{ needs.deploy.outputs.gitrev }}> landed on <https://moonbase.mw.zone|moonbase> refer to the <https://moonbase.mw.zone/docs|docs>"
},
"accessory": {
"type": "image",
"image_url": "https://moonbase.mw.zone/assets/logo.png",
"alt_text": "moonbase logo"
}
}
]
}