diff --git a/README.md b/README.md index 40b4d72..f6a5ff5 100644 --- a/README.md +++ b/README.md @@ -45,7 +45,7 @@ autorestic_restic_install_directory: The directories to install the autorestic and restic binaries at. ```yaml -autorestic_config: |- +autorestic_config: version: 2 locations: home: @@ -53,7 +53,6 @@ autorestic_config: |- to: remote # Every Monday cron: "0 0 * * MON" - backends: remote: type: b2 diff --git a/defaults/main.yml b/defaults/main.yml index 8a85acc..821cc0d 100644 --- a/defaults/main.yml +++ b/defaults/main.yml @@ -6,7 +6,7 @@ autorestic_install_directory: path: /opt/autorestic/bin autorestic_restic_install_directory: path: /opt/restic/bin -autorestic_config: |- +autorestic_config: version: 2 locations: home: @@ -14,7 +14,6 @@ autorestic_config: |- to: remote # Every Monday cron: "0 0 * * MON" - backends: remote: type: b2 diff --git a/tasks/main.yml b/tasks/main.yml index b14fd5a..5c9c708 100644 --- a/tasks/main.yml +++ b/tasks/main.yml @@ -47,7 +47,7 @@ - name: Create autorestic configuration file ansible.builtin.copy: - content: "{{ autorestic_config }}" + content: "{{ autorestic_config | to_yaml }}" dest: ~/.autorestic.yml mode: "0600"