[Service]
# Execute the initialization sequence and apply ACLs only if the Nvidia kernel module is loaded.
ExecStartPre=+/bin/sh -c 'if [ -d /sys/module/nvidia ]; then /usr/bin/nvidia-modprobe -m && /usr/bin/nvidia-smi -L && /usr/bin/setfacl -m g:gdm:rw- /dev/nvidia0 /dev/nvidiactl /dev/nvidia-modeset 2>/dev/null || true; fi'