Correct way of adding boot/shutdown & suspend/resume hooks?

I am about to install Bazzite on my HTPC. Before I dive in, I want to figure out how to add boot/shutdown & suspend/resume hooks. On my current arch installation I just put some custom .service files into /etc/systemd/system, but since this is my first immutable filesystem, I am not sure what the correct way to achieve this would be. I just need to execute a script (changing the input on my AVR) when the system starts/stops. Cheers!
Solution:
/etc is writable /usr however is not with the exception of /usr/local which is symlinked to /var/usrlocal...
Jump to solution
3 Replies
Solution
HikariKnight
HikariKnight7mo ago
/etc is writable /usr however is not with the exception of /usr/local which is symlinked to /var/usrlocal
Matthias
Matthias7mo ago
So they will persist updates if I put them in /etc? Cool thanks!
HikariKnight
HikariKnight7mo ago
yes