diff --git a/tasks/main.yml b/tasks/main.yml index f2e7979..c3a554b 100644 --- a/tasks/main.yml +++ b/tasks/main.yml @@ -27,7 +27,7 @@ lineinfile: path: "/home/{{ item }}/.bashrc" regexp: '^su() ' - line: "su() { if [[ $1 == "-" ]]; then command machinectl shell --uid "$2"; else command machinectl shell --uid "$1"; fi; }" + line: "su() { if [[ $1 == \"-\" ]]; then command machinectl shell --uid \"$2\"; else command machinectl shell --uid \"$1\"; fi; }" loop: "{{ service_users }}" - lineinfile: