ar- / incron

cron-like daemon which handles filesystem events
Other
229 stars 51 forks source link

Different /tmp than usual - why and where? #89

Closed mviereck closed 2 years ago

mviereck commented 2 years ago

Hello,

I found that incron somehow provides a different /tmp in incron scripts than the /tmp I see regulary. Am I right? Why is that done, and can that be disabled? Where is /tmp within incron scripts?

This caused issues in https://github.com/mviereck/x11docker/issues/393

versable commented 2 years ago

This is due to how /tmp is handled today. Usually it is separated through system namespaces and bind mounts. See: https://systemd.io/TEMPORARY_DIRECTORIES/

mviereck commented 2 years ago

Thank you for the clarification! Meanwhile the problem has been solved with another incrontab related tool.

Just out of curiosity: What if one wants to watch files in /tmp?

eworm-de commented 2 years ago

Just overwrite the setting in unit file. Create /etc/systemd/system/incrond.service.d/PrivateTmp.conf with this content:

[Service]
PrivateTmp=false
mviereck commented 2 years ago

Thank you! That is a quite useful hint.