diff --git a/releasenotes/notes/quote-$@-a3d47106c9b7eeb6.yaml b/releasenotes/notes/quote-$@-a3d47106c9b7eeb6.yaml new file mode 100644 index 000000000..51e7c8bcd --- /dev/null +++ b/releasenotes/notes/quote-$@-a3d47106c9b7eeb6.yaml @@ -0,0 +1,5 @@ +--- +fixes: + - The generated ansible-playbook-command.sh now has quotes around $@ so + that the value can be passed through to ansible-playbook with spaces or + other characters requiring quotes. diff --git a/tripleo_common/actions/ansible.py b/tripleo_common/actions/ansible.py index c4c2e42f5..c7fe4f626 100644 --- a/tripleo_common/actions/ansible.py +++ b/tripleo_common/actions/ansible.py @@ -462,7 +462,7 @@ class AnsiblePlaybookAction(base.TripleOAction): f.write('%s="%s"\n' % (var, env_variables[var])) f.write('\n') f.write(' '.join(command)) - f.write(' $@') + f.write(' "$@"') f.write('\n') os.chmod(command_path, 0o750)