Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

created config_change_alert.yaml #1118

Merged
merged 1 commit into from Apr 1, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
33 changes: 33 additions & 0 deletions .github/workflows/config_change_alert.yaml
@@ -0,0 +1,33 @@
name: config_change_alert

on:
push:
branches:
- staging
pull_request:
branches:
- staging

jobs:
test:
runs-on: docker-builds
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 0 # OR "2" -> To retrieve the preceding commit.

- name: Get changed files using defaults
id: changed-files
uses: tj-actions/changed-files@v18.4

- name: Run step when a 0chain.yaml file changes
if: contains(steps.changed-files.outputs.modified_files, 'docker.local/config/0chain.yaml')
run: |
echo "Your 0chain.yaml file has been modified."
curl -X POST -H 'Content-type: application/json' --data '{"text":"Your 0chain.yaml config file has been modified."}' ${{ secrets.CHAT_WEBHOOK_URL }}

- name: Run step when a sc.yaml file changes
if: contains(steps.changed-files.outputs.modified_files, 'docker.local/config/sc.yaml')
run: |
echo "Your sc.yaml file has been modified."
curl -X POST -H 'Content-type: application/json' --data '{"text":"Your sc.yaml config file has been modified."}' ${{ secrets.CHAT_WEBHOOK_URL }}