network-outage-simulation #60
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: network-outage-simulation | |
on: | |
workflow_dispatch: | |
schedule: | |
# * is a special character in YAML so you have to quote this string | |
# Run every day at 7 AM. (The database backup is created around 5 AM.) | |
- cron: "0 7 * * *" | |
jobs: | |
run_sim: | |
runs-on: [self-hosted, linux, x64, net-outage-sim] | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Cleanup docker (avoid conflicts with previous runs) | |
shell: bash | |
run: .github/workflows/cleanup-net-outage-sim.sh | |
- name: Download avalanchego:latest | |
run: docker pull avaplatform/avalanchego:latest | |
- name: Run the internet outage simulation | |
shell: bash | |
run: .github/workflows/run-net-outage-sim.sh | |
- name: Cleanup again | |
if: always() # Always clean up | |
shell: bash | |
run: .github/workflows/cleanup-net-outage-sim.sh |