mybuddy/.github/workflows/demo-reset.yml

23 lines
602 B
YAML
Raw Normal View History

2022-05-22 22:41:06 +00:00
name: Demo reset
on:
schedule:
- cron: "0 */3 * * *"
workflow_dispatch:
2022-05-22 22:41:06 +00:00
jobs:
reset:
name: Reset
runs-on: ubuntu-latest
2022-06-03 03:48:37 +00:00
environment:
name: demo
url: https://demo.baby-buddy.net
2022-05-22 22:41:06 +00:00
steps:
- uses: actions/checkout@v3
2022-06-03 04:34:04 +00:00
- uses: ./.github/actions/setup
2022-06-02 17:29:48 +00:00
- name: Install Railway CLI
2022-06-11 02:47:40 +00:00
run: npm install --location=global @railway/cli
2022-06-02 17:29:48 +00:00
- name: Reset demo database
2022-06-02 18:41:30 +00:00
run: npx railway run pipenv run python manage.py reset --no-input
2022-06-02 17:29:48 +00:00
env:
DJANGO_SETTINGS_MODULE: babybuddy.settings.railway
RAILWAY_TOKEN: ${{ secrets.RAILWAY_TOKEN }}