--- - name: backup_ovh1 hosts: localhost gather_facts: false vars_files: main.yml tasks: - name: Assert environment variable is not empty ansible.builtin.include_tasks: "tasks/assert_env_var_not_empty.yml" with_items: "{{ BACKUP_OVH1_REQUIRED_ENV_VARS }}" - name: Create backup directory ansible.builtin.file: path: "{{ WORKDIR }}/backup" state: directory # python3-swiftclient is a requirement of duplicity - name: Install python3-swiftclient ansible.builtin.package: name: python3-swiftclient state: present - name: Backup standard volume ansible.builtin.include_tasks: "tasks/backup_volume.yml" with_items: "{{ BACKUP_OVH1_VOLUMES }}" - name: Prepare MySQL_DB backup volume ansible.builtin.include_tasks: "tasks/prepare_MySQL_DB_backup_volume.yml" - name: Backup last MySQL dumps ansible.builtin.include_tasks: "tasks/backup_volume.yml" with_items: - name: MySQL_DB dir: "{{ WORKDIR }}/backup/MySQL_DB"