)]}'
{"tripleo_ansible/roles/backup-and-restore/defaults/main.yml":[{"author":{"_account_id":7353,"name":"Kevin Carter","email":"kevin@cloudnull.com","username":"cloudnull"},"change_message_id":"663f5ddc1fbc3312f41d03579fd3884a55434290","unresolved":false,"context_lines":[{"line_number":30,"context_line":"tripleo_backup_and_restore_exclude_paths_controller: [\u0027/var/lib/mysql/*\u0027]"},{"line_number":31,"context_line":"tripleo_backup_and_restore_exclude_paths_compute: [\u0027/var/lib/nova/instances/*\u0027]"},{"line_number":32,"context_line":"tripleo_backup_and_restore_hiera_config_file: \"/etc/puppet/hiera.yaml\""},{"line_number":33,"context_line":"tripleo_backup_and_restore_extra_local_config:"},{"line_number":34,"context_line":"  ISO_DEFAULT: \u0027\"atomatic\"\u0027"},{"line_number":35,"context_line":"  USING_UEFI_BOOTLOADER: 0"},{"line_number":36,"context_line":"  OUTPUT: ISO"}],"source_content_type":"text/x-yaml","patch_set":2,"id":"3fa7e38b_45407608","line":33,"updated":"2019-09-17 13:55:04.000000000","message":"It\u0027d be nice to add a comment here that indicates this hash requires strings to be single then double quoted because it will be used in configuration file which is interpreted by BASH.","commit_id":"f7f1b37491e65f344e4c7408e51632708ab47305"},{"author":{"_account_id":8932,"name":"Telles Mota Vidal Nóbrega","email":"tellesnobrega@gmail.com","username":"tellesnobrega"},"change_message_id":"d5cfdd3b61e194fd14043b4d24a11f32be8949f2","unresolved":false,"context_lines":[{"line_number":31,"context_line":"tripleo_backup_and_restore_exclude_paths_compute: [\u0027/var/lib/nova/instances/*\u0027]"},{"line_number":32,"context_line":"tripleo_backup_and_restore_hiera_config_file: \"/etc/puppet/hiera.yaml\""},{"line_number":33,"context_line":"tripleo_backup_and_restore_extra_local_config:"},{"line_number":34,"context_line":"  ISO_DEFAULT: \u0027\"atomatic\"\u0027"},{"line_number":35,"context_line":"  USING_UEFI_BOOTLOADER: 0"},{"line_number":36,"context_line":"  OUTPUT: ISO"},{"line_number":37,"context_line":"  BACKUP: NETFS"}],"source_content_type":"text/x-yaml","patch_set":2,"id":"3fa7e38b_fcc57f5c","line":34,"updated":"2019-09-17 11:52:21.000000000","message":"should this be automatic?","commit_id":"f7f1b37491e65f344e4c7408e51632708ab47305"},{"author":{"_account_id":7353,"name":"Kevin Carter","email":"kevin@cloudnull.com","username":"cloudnull"},"change_message_id":"663f5ddc1fbc3312f41d03579fd3884a55434290","unresolved":false,"context_lines":[{"line_number":31,"context_line":"tripleo_backup_and_restore_exclude_paths_compute: [\u0027/var/lib/nova/instances/*\u0027]"},{"line_number":32,"context_line":"tripleo_backup_and_restore_hiera_config_file: \"/etc/puppet/hiera.yaml\""},{"line_number":33,"context_line":"tripleo_backup_and_restore_extra_local_config:"},{"line_number":34,"context_line":"  ISO_DEFAULT: \u0027\"atomatic\"\u0027"},{"line_number":35,"context_line":"  USING_UEFI_BOOTLOADER: 0"},{"line_number":36,"context_line":"  OUTPUT: ISO"},{"line_number":37,"context_line":"  BACKUP: NETFS"}],"source_content_type":"text/x-yaml","patch_set":2,"id":"3fa7e38b_85750e9b","line":34,"in_reply_to":"3fa7e38b_fcc57f5c","updated":"2019-09-17 13:55:04.000000000","message":"+1","commit_id":"f7f1b37491e65f344e4c7408e51632708ab47305"}],"tripleo_ansible/roles/backup-and-restore/setup_rear/tasks/main.yml":[{"author":{"_account_id":20775,"name":"Carlos Camacho","email":"ccamacho@redhat.com","username":"ccamacho"},"change_message_id":"82a417b043dea20e2a0159d91537941e55c9f8e4","unresolved":false,"context_lines":[{"line_number":85,"context_line":"  tags:"},{"line_number":86,"context_line":"    - bar_setup_rear"},{"line_number":87,"context_line":""},{"line_number":88,"context_line":"- name: Add extra ReaR config variables into the local.conf"},{"line_number":89,"context_line":"  become: true"},{"line_number":90,"context_line":"  lineinfile:"},{"line_number":91,"context_line":"    path: /etc/rear/local.conf"},{"line_number":92,"context_line":"    line: \"{{ item.key }}\u003d{{ item.value }}\""},{"line_number":93,"context_line":"    insertafter: EOF"},{"line_number":94,"context_line":"  loop: \"{{ lookup(\u0027dict\u0027, tripleo_backup_and_restore_extra_local_config) }}\""},{"line_number":95,"context_line":"  tags:"},{"line_number":96,"context_line":"    - bar_setup_rear"},{"line_number":97,"context_line":""},{"line_number":98,"context_line":"- name: Generate ReaR rescue file"},{"line_number":99,"context_line":"  become: true"}],"source_content_type":"text/x-yaml","patch_set":2,"id":"3fa7e38b_9c9a4bc3","line":96,"range":{"start_line":88,"start_character":0,"end_line":96,"end_character":20},"updated":"2019-09-17 11:38:59.000000000","message":"I think you can delegate this task to the actual template. i.e. as we do it here:\n\nhttps://github.com/openstack/tripleo-ansible/blob/master/tripleo_ansible/roles/backup-and-restore/templates/local.conf.j2#L19\n\nThe thing is how can we make sure, we don\u0027t have colliding config parameters?\n\nAn example of this can be if you allow the parameter BACKUP: NETFS to be different, it will collide with i.e. OUTPUT_URL\u003dnfs:// as it might not be NFS.\n\nI think this change is something good to have, but I personally vote to move them all (not only the extra parameters) to avoid this possible parameters incompatibility.\n\nWDYT to add to your default variable all the config parameters and then use some Jinja kung-fu to create the file based on the content of tripleo_backup_and_restore_extra_local_config ? In which case I would rename it as tripleo_backup_and_restore_config_local\n\nThen (in a follow up patch) we can extend it to the other config files like:\n\n  tripleo_backup_and_restore_config_exports\n  tripleo_backup_and_restore_config_rescue","commit_id":"f7f1b37491e65f344e4c7408e51632708ab47305"},{"author":{"_account_id":7353,"name":"Kevin Carter","email":"kevin@cloudnull.com","username":"cloudnull"},"change_message_id":"663f5ddc1fbc3312f41d03579fd3884a55434290","unresolved":false,"context_lines":[{"line_number":85,"context_line":"  tags:"},{"line_number":86,"context_line":"    - bar_setup_rear"},{"line_number":87,"context_line":""},{"line_number":88,"context_line":"- name: Add extra ReaR config variables into the local.conf"},{"line_number":89,"context_line":"  become: true"},{"line_number":90,"context_line":"  lineinfile:"},{"line_number":91,"context_line":"    path: /etc/rear/local.conf"},{"line_number":92,"context_line":"    line: \"{{ item.key }}\u003d{{ item.value }}\""},{"line_number":93,"context_line":"    insertafter: EOF"},{"line_number":94,"context_line":"  loop: \"{{ lookup(\u0027dict\u0027, tripleo_backup_and_restore_extra_local_config) }}\""},{"line_number":95,"context_line":"  tags:"},{"line_number":96,"context_line":"    - bar_setup_rear"},{"line_number":97,"context_line":""},{"line_number":98,"context_line":"- name: Generate ReaR rescue file"},{"line_number":99,"context_line":"  become: true"}],"source_content_type":"text/x-yaml","patch_set":2,"id":"3fa7e38b_05dcbe72","line":96,"range":{"start_line":88,"start_character":0,"end_line":96,"end_character":20},"in_reply_to":"3fa7e38b_9c9a4bc3","updated":"2019-09-17 13:55:04.000000000","message":"+1 if we want to amend a file with content like this we might want to use blockinfile\n\n  - name: Add extra ReaR config variables into the local.conf\n    blockinfile:\n      path: /etc/rear/local.conf\n      block: |\n        {% for k, v in (tripleo_backup_and_restore_extra_local_config | dict2items) %}\n        {{ k }}\u003d{{ v }}\n        {% endfor %}\n\nSomething like this will be faster and more sustainable.","commit_id":"f7f1b37491e65f344e4c7408e51632708ab47305"}]}
