Skip to content

Deploy and Destroy Workflows #63

Deploy and Destroy Workflows

Deploy and Destroy Workflows #63

name: "Deploy and Destroy Workflows"
on:
schedule:
- cron: '30 8 * * 0'
- cron: '30 9 * * 0'
- cron: '30 12 * * 0'
- cron: '30 14 * * 0'
jobs:
usecase_schedule:
name: "Trigger Actions Schedules"
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Trigger Deploy workflow
run: gh workflow run bot-defense-re-deploy.yaml --ref bot-defense-re
if: github.event.schedule == '30 88 * * 0'
env:
GH_TOKEN: ${{ secrets.ACTIONS_SECRET }}
- name: Trigger Destroy workflow
run: gh workflow run bot-defense-re-destroy.yaml --ref destroy-bot-defense-re
if: github.event.schedule == '30 98 * * 0'
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Trigger Deploy workflow
run: gh workflow run waf-on-ce-aws-apply.yml --ref deploy-waf-aws-ce
if: github.event.schedule == '30 128 * * 0'
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Trigger Destroy workflow
run: gh workflow run waf-on-ce-aws-destroy.yml --ref destroy-waf-aws-ce
if: github.event.schedule == '30 148 * * 0'
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}