remove all datetime variables.
This commit is contained in:
@@ -19,14 +19,14 @@
|
||||
label: "{{ item.name }}"
|
||||
|
||||
- name: Create backup of mysql database and store to backup directory
|
||||
shell: docker exec {{ item[1].container }} mysqldump -u{{ item[1].user }} -p{{ item[1].pass }} {{ item[1].name }} > {{ backup_location }}{{ item[0].name }}/{{ item[1].container }}-{{ ansible_date_time.iso8601_basic_short }}.sql
|
||||
shell: docker exec {{ item[1].container }} mysqldump -u{{ item[1].user }} -p{{ item[1].pass }} {{ item[1].name }} > {{ backup_location }}{{ item[0].name }}/{{ item[1].container }}-{{ date }}.sql
|
||||
when: item[1].type == "mysql"
|
||||
loop: "{{ containers | subelements('database', skip_missing=True) }}"
|
||||
loop_control:
|
||||
label: "{{ item[1].name }}"
|
||||
|
||||
- name: Create backup of postgres database and store to backup directory
|
||||
shell: docker exec {{ item[1].container }} pg_dump -U {{ item[1].user }} {{ item[1].name }} > {{ backup_location }}{{ item[0].name }}/{{ item[1].container }}-{{ ansible_date_time.iso8601_basic_short }}.sql
|
||||
shell: docker exec {{ item[1].container }} pg_dump -U {{ item[1].user }} {{ item[1].name }} > {{ backup_location }}{{ item[0].name }}/{{ item[1].container }}-{{ date }}.sql
|
||||
when: item[1].type == "psql"
|
||||
loop: "{{ containers | subelements('database', skip_missing=True) }}"
|
||||
loop_control:
|
||||
|
||||
Reference in New Issue
Block a user