Closed hafu closed 1 year ago
Thank you for the contribution 🚀
This is a regression! See https://github.com/patrickjahns/ansible-role-promtail/issues/140
In fact, is home
really needed? Since we already have createhome: False
. I don't know why it's needed at all.
In fact, is
home
really needed? Since we already havecreatehome: False
. I don't know why it's needed at all.
This is a good point. The home
parameter in the Ansible user module is optional. Would be interesting to what it will be set on new installations. I guess /home/promtail
. On existing installations it won't be touched. Sounds like a good solution. I will check this the next days.
This PR sets the home directory of the promtail user to the
promtail_install_dir
(/opt/promtail
).When reverting the installation with ansible a
/
as home could lead to the deletion of the whole system when using ansible.builtin.user module with:This may be a edge case, since ansible defaults are safe. But setting the home to a safer location prevents from deleting the whole root.