1
0
Fork 0
mirror of https://github.com/iiab/iiab.git synced 2025-03-09 15:40:17 +00:00

tweek udev rules & usbmount@.service

This commit is contained in:
Jerry Vonau 2025-02-15 10:45:44 -06:00
parent e80b912eea
commit 20cda93f23
2 changed files with 2 additions and 3 deletions

View file

@ -1,3 +1,2 @@
ACTION=="add", SUBSYSTEMS=="usb", SUBSYSTEM=="block", ENV{ID_FS_USAGE}=="filesystem" PROGRAM="/bin/systemd-escape -p --template=usbmount@.service $env{DEVNAME}", ENV{SYSTEMD_WANTS}+="%c"
ACTION=="remove", SUBSYSTEMS=="usb", SUBSYSTEM=="block", ENV{ID_FS_USAGE}=="filesystem" PROGRAM="/bin/systemd-escape -p /usr/share/usbmount/usbmount remove"
ACTION=="remove", SUBSYSTEMS=="usb", SUBSYSTEM=="block", ENV{ID_FS_USAGE}=="filesystem" PROGRAM="/bin/systemd-escape -p --template=usbmount@.service $env{DEVNAME}"

View file

@ -10,6 +10,6 @@ TimeoutStartSec=0
Environment=DEVNAME=%I
ExecStart=/usr/local/sbin/usbmount add
ExecStop=/usr/local/sbin/iiab-clean-usb.sh %I
ExecStopPost=/bin/umount /%I
ExecStopPost=/usr/local/sbin/usbmount remove
RemainAfterExit=yes
RuntimeDirectory=usbmount