)]}'
{"scripts/upgrade-utilities/playbooks/user-secrets-adjustment.yml":[{"author":{"_account_id":22525,"name":"Qin Wang (qwang)","email":"qin.wang@intel.com","username":"qwang"},"change_message_id":"b4c5cb17faa2b9bf40ab877616de21d57522bea4","unresolved":false,"context_lines":[{"line_number":30,"context_line":"        dest: \"/etc/openstack_deploy/{{ _osa_secrets_file_name }}\""},{"line_number":31,"context_line":"        line: \"{{ item }}\""},{"line_number":32,"context_line":"      with_items: \"{{ secrets.stdout_lines }}\""},{"line_number":33,"context_line":"      when: user_secrets.stdout.find(\"{{ item }}\") \u003d\u003d -1"},{"line_number":34,"context_line":"    - name: Generate new secrets"},{"line_number":35,"context_line":"      shell: \"{{ playbook_dir }}/../../../scripts/pw-token-gen.py --file /etc/openstack_deploy/{{ _osa_secrets_file_name }}\""},{"line_number":36,"context_line":"  vars:"}],"source_content_type":"text/x-yaml","patch_set":1,"id":"5a8bc5a2_ace98282","line":33,"updated":"2016-09-23 18:52:07.000000000","message":"my understanding is the \"lineinfile\" module already check if the line exists and if not, it will insert the line. So, it is not necessary to have the \"when\" condition.","commit_id":"99b2747f4d908ea16be7032ddba9fbca765ca615"},{"author":{"_account_id":14805,"name":"Jimmy McCrory","email":"jimmy.mccrory@gmail.com","username":"jimmy-mccrory"},"change_message_id":"2fd581cc5bc87c45e43f9cb43745325335c9f6a6","unresolved":false,"context_lines":[{"line_number":30,"context_line":"        dest: \"/etc/openstack_deploy/{{ _osa_secrets_file_name }}\""},{"line_number":31,"context_line":"        line: \"{{ item }}\""},{"line_number":32,"context_line":"      with_items: \"{{ secrets.stdout_lines }}\""},{"line_number":33,"context_line":"      when: user_secrets.stdout.find(\"{{ item }}\") \u003d\u003d -1"},{"line_number":34,"context_line":"    - name: Generate new secrets"},{"line_number":35,"context_line":"      shell: \"{{ playbook_dir }}/../../../scripts/pw-token-gen.py --file /etc/openstack_deploy/{{ _osa_secrets_file_name }}\""},{"line_number":36,"context_line":"  vars:"}],"source_content_type":"text/x-yaml","patch_set":1,"id":"5a8bc5a2_671cf477","line":33,"in_reply_to":"5a8bc5a2_ace98282","updated":"2016-09-23 19:55:35.000000000","message":"The \"when\" is to prevent replacing any secrets that have an existing password.\nlineinfile will write \u0027line\u0027 exactly as it is, so this task only writes each \"secret_name:\" out to the file.","commit_id":"99b2747f4d908ea16be7032ddba9fbca765ca615"}]}
