Add pull-from-prod to Makefile

Add `pull-from-prod` to the Makefile, which downloads a database from
production, imports it and runs the post-import steps.

Fixes #79
This commit is contained in:
Oliver Davies 2020-06-01 12:38:58 +01:00
parent 4a2aa00ce2
commit 208d535d95
2 changed files with 17 additions and 6 deletions

View file

@ -6,13 +6,10 @@
vars_files:
- vars/vars.yml
tasks:
- name: Generate the name for the export
set_fact:
export_filename: "~/{{ lookup('pipe', 'date -u +%Y%m%d%H%M%SZ') }}.sql"
run_once: true
when: export_filename is not defined
vars:
export_filename: /tmp/dump.sql
tasks:
- name: Export the database
command:
cmd: >