ansible-opnsense icon indicating copy to clipboard operation
ansible-opnsense copied to clipboard

`srm` does not exist on macOS.

Open reitermarkus opened this issue 2 years ago • 2 comments

rm -P overwrites the file three times before deleting.

reitermarkus avatar Feb 19 '22 13:02 reitermarkus

On Alpine Linux the secure-delete package is also not available however the -P option does not exist here. Had to work around it by creating a /bin/srm script that would do rm $@ ...

How reliable is secure delete, e.g. on journaling file systems? Does it even make sense to use it? Should we maybe use a flag to switch to normal delete ?

domoran avatar Aug 11 '22 08:08 domoran

maybe it would be the most ansiblish and os independent way to just use

- name: clean, delete
  delegate_to: localhost
  file:
    path: "{{ local_config_path }}"
    state: absent
  tags: clean

In our clone of the repo we disabled conditionally the step by default https://github.com/Rosa-Luxemburgstiftung-Berlin/ansible-opnsense/blob/main/tasks/main.yml#L256:L260 as we keep the config and store it in our git repo https://github.com/Rosa-Luxemburgstiftung-Berlin/ansible-opnsense-playbook

zerwes avatar Aug 11 '22 09:08 zerwes