Skip to content

scheduled_backup workflow test #2

scheduled_backup workflow test

scheduled_backup workflow test #2

Workflow file for this run

---
name: Backup the database with fac-backup-utility
on:
workflow_call:
inputs:
environment:
required: true
type: string
default: "preview"
db_to_db_operation:
required: false
type: string
default: "backup"
s3_restore_folder_date:
required: false
type: string
push:
branches: [as/db-backup-util]
jobs:
fac-backup:
# if: contains('["asteel-gsa","x", "y", "z"]', github.actor)
name: Perform Database Backup
runs-on: ubuntu-latest
# environment: ${{ inputs.environment }}
environment: "preview"
env:
# space: ${{ inputs.environment }}
space: "preview"
steps:
- name: Backup FAC Database and Sync Media
uses: cloud-gov/cg-cli-tools@main
with:
cf_username: ${{ secrets.CF_USERNAME }}
cf_password: ${{ secrets.CF_PASSWORD }}
cf_org: gsa-tts-oros-fac
cf_space: ${{ env.space }}
command: cf run-task gsa-fac -k 3G -m 2G --name backup_db --command "./fac-backup-util.sh v0.1.2 scheduled_backup"
### Common Commands:
# ./fac-backup-util.sh v0.1.2 initial_backup
# ./fac-backup-util.sh v0.1.2 deploy_backup
# ./fac-backup-util.sh v0.1.2 scheduled_backup
# ./fac-restore-util.sh v0.1.2 s3_restore 202405301232
# ./fac-restore-util.sh v0.1.2 db_restore