mirror of
https://github.com/k3s-io/k3s-ansible.git
synced 2025-12-25 00:12:37 +01:00
Only apply K3s autocomplete when ansible_user is defined (#398)
Signed-off-by: Derek Nola <derek.nola@suse.com>
This commit is contained in:
@@ -35,6 +35,7 @@
|
|||||||
changed_when: true
|
changed_when: true
|
||||||
|
|
||||||
- name: Add K3s autocomplete to user bashrc
|
- name: Add K3s autocomplete to user bashrc
|
||||||
|
when: ansible_user is defined
|
||||||
ansible.builtin.lineinfile:
|
ansible.builtin.lineinfile:
|
||||||
path: "~{{ ansible_user }}/.bashrc"
|
path: "~{{ ansible_user }}/.bashrc"
|
||||||
regexp: '\.\s+<\(k3s completion bash\)'
|
regexp: '\.\s+<\(k3s completion bash\)'
|
||||||
|
|||||||
Reference in New Issue
Block a user