21 lines
489 B
YAML
21 lines
489 B
YAML
- name: stop before restore
|
|
shell: |
|
|
docker-compose down
|
|
args:
|
|
chdir: /opt/{{ docker_wordpress_service_id }}/
|
|
|
|
- name: restore
|
|
shell: |
|
|
rsync -a --delete "{{ docker_wordpress_backup_dir }}/{{ docker_wordpress_service_id }}/{{ item }}" "{{ docker_wordpress_data_dir }}/{{ docker_wordpress_service_id }}/"
|
|
with_items:
|
|
- mysql
|
|
- wp_html
|
|
|
|
- name: start after restore
|
|
shell: |
|
|
docker-compose up -d
|
|
args:
|
|
chdir: /opt/{{ docker_wordpress_service_id }}/
|
|
|
|
|
|
|