mirror of
https://github.com/kerberos-io/deployment.git
synced 2026-08-23 15:18:32 +00:00
Slack notifications for success and failure have been added to the k3d, kind, kustomize, microk8s, and pr-description GitHub Actions workflows. This improves visibility of deployment and PR automation results by sending status updates to a configured Slack channel.
36 lines
1.7 KiB
YAML
36 lines
1.7 KiB
YAML
name: Autofill PR description
|
|
|
|
on: pull_request
|
|
|
|
jobs:
|
|
openai-pr-description:
|
|
runs-on: ubuntu-22.04
|
|
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- name: Autofill PR description if empty using OpenAI
|
|
uses: cedricve/azureopenai-pr-description@master
|
|
with:
|
|
github_token: ${{ secrets.TOKEN }}
|
|
openai_api_key: ${{ secrets.OPENAI_API_KEY }}
|
|
azure_openai_api_key: ${{ secrets.AZURE_OPENAI_API_KEY }}
|
|
azure_openai_endpoint: ${{ secrets.AZURE_OPENAI_ENDPOINT }}
|
|
azure_openai_version: ${{ secrets.AZURE_OPENAI_VERSION }}
|
|
overwrite_description: true
|
|
- name: Send Slack Notification on Success
|
|
if: success()
|
|
env:
|
|
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
|
|
run: |
|
|
curl -X POST -H 'Content-type: application/json' --data "{
|
|
\"text\": \"✅ PR Description Auto-fill Successful! :robot_face:\n*Workflow*: ${{ github.workflow }}\n*PR*: ${{ github.event.pull_request.title }}\n*Triggered by*: ${{ github.actor }}\n*Repository*: ${{ github.repository }}\"
|
|
}" $SLACK_WEBHOOK_URL
|
|
- name: Send Slack Notification on Failure
|
|
if: failure()
|
|
env:
|
|
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
|
|
run: |
|
|
curl -X POST -H 'Content-type: application/json' --data "{
|
|
\"text\": \"❌ PR Description Auto-fill Failed! :x:\n*Workflow*: ${{ github.workflow }}\n*PR*: ${{ github.event.pull_request.title }}\n*Triggered by*: ${{ github.actor }}\n*Repository*: ${{ github.repository }}\n*Run URL*: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}\"
|
|
}" $SLACK_WEBHOOK_URL
|