What I want to do
Essentially I want to do this
~/.config/systemd/user/me_unit.service ----------------------- [Unit] Description="Unmount thing" [Service] User=root Group=root ExecStop=/home/failuregod/.config/systemd/user/unmount.py RemainAfterExit=yes [Install] WantedBy=default.target
What I tried
sudo systemd --user enable me_unit.service
This doesn't work. I get the following error
Failed to connect to bus: No such file or directory.
I also tried without sudo but then I'm not allowed to switch the user to root (understandably)
What I'm trying to do
I triple (or more) boot my computer and I want all my linux partitions to use the same Documents and Downloads folders but different homes. My spectacular idea was to use zfs and make multiple home datasets and one Docuemnt and one Downloads dataset.
The initial unlock will be done with pam_exec but I was hoping to use systemd to unmount the datasets. I want to avoid, if possible, having to like somehow stuff my username into the unit then check for usernames in the unmount script.