Merge pull request #466 from AikidoSec/slack-url-secret

Store the slack url as a secret
This commit is contained in:
bitterpanda 2026-05-20 10:10:10 -07:00 committed by GitHub
commit fd01d9f31b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -58,6 +58,7 @@ jobs:
if: steps.latest.outputs.version != steps.current.outputs.version if: steps.latest.outputs.version != steps.current.outputs.version
env: env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
run: | run: |
NEW="${{ steps.latest.outputs.version }}" NEW="${{ steps.latest.outputs.version }}"
OLD="${{ steps.current.outputs.version }}" OLD="${{ steps.current.outputs.version }}"
@ -76,6 +77,6 @@ jobs:
git push origin "$BRANCH" git push origin "$BRANCH"
PR_URL="https://github.com/${{ github.repository }}/compare/main...${BRANCH}?expand=1" PR_URL="https://github.com/${{ github.repository }}/compare/main...${BRANCH}?expand=1"
curl -s -X POST "https://hooks.slack.com/triggers/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" \ curl -s -X POST "$SLACK_WEBHOOK_URL" \
-H "Content-Type: application/json" \ -H "Content-Type: application/json" \
-d "{\"text\": \"update to ${NEW} - ${PR_URL}\"}" -d "{\"text\": \"update to ${NEW} - ${PR_URL}\"}"