How to run Syncthing on NAS542 as non-root, or elseway provide synced data rw possibility for users?
I have admin and non-admin users on my NAS542, connected to NAS shares though Windows share drives accordingly to their NAS users (not as root). Although, when Syncthing (started as root from /opt/bin through /opt/etc/init.d/S92syncthing) copies new data from devices to NAS, all such files are set to root:root, so nor admin, nor non-admin users cannot edit, move, delete data from Windows clients. How can I solve this situation?
All Replies
-
There no sudo, no sudoers file, no runuser command, no PAM at NAS542. No option like "—run-as-user" in syncthing. No possibility to run syncthing as a per-user service. Set chown of "syncthing" file as new user "syncthing" and group "everyone" is futile - all newly synced file, of cource, are root:root, because "syncthing" file called by root process.
0 -
Of course, checkbox "Ignore permissions" in syncthing shared folders are checked.
0 -
At least how to make synced files/dirs to have mod 666, not 644! 😣
Of course, I can manually set permission of directories (to possibility of move/delete files inside) or files (for possibility to edit them), but do it every time, after each sync, for each new directory or file I need to edit on Windows, where I logged as admin… 😓
0 -
The is no sudo, but you have su. From the startscript of my Pulse package:
Startup()
{
mkdir -p ${PKG_HOME}
chown ${PKG_USER} ${PKG_HOME} su -m ${PKG_USER} -s /bin/sh -c "HOME=$PKG_HOME ${PKG_ROOT}/bin/${PKG_DAEMON} -home=$PKG_HOME -gui-address=\"$( GetLink )\" >${PKG_HOME}/lastlog 2>&1 & " }0
Categories
- All Categories
- 415 Beta Program
- 2.4K Nebula
- 151 Nebula Ideas
- 98 Nebula Status and Incidents
- 5.7K Security
- 277 USG FLEX H Series
- 277 Security Ideas
- 1.4K Switch
- 74 Switch Ideas
- 1.1K Wireless
- 42 Wireless Ideas
- 6.4K Consumer Product
- 250 Service & License
- 395 News and Release
- 85 Security Advisories
- 29 Education Center
- 10 [Campaign] Zyxel Network Detective
- 3.6K FAQ
- 34 Documents
- 34 Nebula Monthly Express
- 85 About Community
- 75 Security Highlight