1616 - " sanchogov.tools/api"
1717 - " staging.govtool.byron.network/api"
1818 - " govtool.cardanoapi.io/api"
19+ - " be.preview.gov.tools"
1920 - " z6b8d2f7a-zca4a4c45-gtw.z937eb260.rustrocks.fr"
2021 - " z78acf3c2-z5575152b-gtw.z937eb260.rustrocks.fr"
2122 - " be.gov.tools"
2829 - " preview"
2930 - " mainnet"
3031 - " preprod"
32+
3133 workflow_run :
3234 workflows : ["Build and deploy GovTool test stack"]
3335 types : [completed]
3436 branches :
3537 - test
3638 - infra/test-chores
3739
40+ schedule :
41+ - cron : " 0 0 * * *" # 12AM UTC
42+
3843concurrency :
3944 group : ${{ github.workflow }}-${{ github.ref }}
4045 cancel-in-progress : false
4146
4247jobs :
4348 backend-tests :
4449 runs-on : ubuntu-latest
45- if : ${{ github.event_name == 'workflow_dispatch' || github.event.workflow_run.conclusion == 'success' }}
50+ if : ${{ github.event_name == 'workflow_dispatch' || github.event.workflow_run.conclusion == 'success' || github.event.schedule }}
4651 outputs :
4752 start_time : ${{ steps.set-pending-status.outputs.timestamp }}
4853 status : ${{ steps.run-tests.outcome }}
@@ -115,7 +120,7 @@ jobs:
115120 path : gh-pages
116121 repository : ${{vars.GH_PAGES}}
117122 ssh-key : ${{ secrets.DEPLOY_KEY }}
118-
123+
119124 - name : Remove oldest report to save space
120125 if : ${{success()}}
121126 run : |
@@ -128,6 +133,7 @@ jobs:
128133 run : |
129134 chmod +x .github/scripts/register_report.sh
130135 .github/scripts/register_report.sh
136+
131137 - if : steps.register-project.outputs.project_exists != 'true'
132138 uses : JamesIves/github-pages-deploy-action@v4
133139 with :
@@ -191,7 +197,7 @@ jobs:
191197 GITHUB_TOKEN : ${{ github.token }}
192198
193199env :
194- BASE_URL : https://${{inputs.deployment || 'govtool.cardanoapi.io/api' }}
195- REPORT_NAME : govtool-backend
200+ BASE_URL : https://${{github.event.schedule && 'be.preview.gov.tools' || inputs.deployment || 'govtool.cardanoapi.io/api' }}
201+ REPORT_NAME : ${{ github.event.schedule && 'nightly-'}} govtool-backend
196202 GH_PAGES : ${{vars.GH_PAGES}}
197203 COMMIT_SHA : ${{ github.event.workflow_run.head_sha || github.sha }}
0 commit comments