Comment on Steam deck, Automount Network Share Library in Gamemode
CapillaryUpgrade@lemmy.sdf.org 9 months agoNo problem!
I hacked this together instead of going to sleep, so it might make your deck explode, but maybe it’s a starting point for you or someone else:
# home-deck-mounts.mount # # Mount units must be named after the destination path, this / replaced by -, like above # # This is a template unit. # That's explained here: https://fedoramagazine.org/systemd-template-unit-files/ # TL;DR: run it like this `netmount@linuxisos.mount` if you want to mount the subdirectory "linuxisos" from SHARE_PATH [Unit] Description=NetMount %I After=graphical.target # This is commented out, because it is implicit for network mounts https://www.freedesktop.org/software/systemd/man/latest/systemd.mount.html#Default%20Dependencies # I keep it here as an example #After=network-online.target #Requires=network-online.target [Mount] # %i expands to what ever you put after the @ when starting/activating the service What=10.10.10.99:/mnt/user/%i Where=/home/deck/mounts/%i Type=nfs Options=exec [Install] WantedBy=default.target
I couldn’t confirm if mount units are allowed to be template units, but if not, just duplicate the service for each path and replace %i.
Say the word if you run into issues!