From e972de01f3d645a0e93a0e947c34d15625e0e1d6 Mon Sep 17 00:00:00 2001 From: Oleg Broytman Date: Tue, 8 Mar 2022 21:48:10 +0300 Subject: [PATCH] Fix(root): Remove '.bash_history' Ansible doesn't allow to change type from file to symlink. --- playbooks/roles/root/tasks/root.yml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/playbooks/roles/root/tasks/root.yml b/playbooks/roles/root/tasks/root.yml index 5ca9f96..756af8c 100644 --- a/playbooks/roles/root/tasks/root.yml +++ b/playbooks/roles/root/tasks/root.yml @@ -66,6 +66,12 @@ mode: "0600" when: not sh_history.stat.exists +- name: "Setup ~root - remove .bash_history" + become: true + file: + path: ~root/.bash_history + state: absent + - name: "Setup ~root - link .bash_history" become: true file: -- 2.39.5