Synology - Allow SSH for non-admin users
Problem#
I need to grant regular users SSH access to my Synology NAS, specifically for a Borg account used to back up my TrueNAS.
By default, DSM restricts SSH access to users in the administrators group, as noted at the bottom of this page.
Solution#
The workaround is to modify /etc/passwd and change the target user's shell from /sbin/nologin to a valid shell like /bin/sh.
sed -e '/^borg:/ s:/sbin/nologin:/bin/sh:' -i /etc/passwdPersistence (Task Scheduler)#
To ensure the user retains access after a restart, create a Triggered Task in the Synology Task Scheduler that executes the command on boot.

