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
- 429 Beta Program
- 2.6K Nebula
- 163 Nebula Ideas
- 112 Nebula Status and Incidents
- 6K Security
- 350 USG FLEX H Series
- 291 Security Ideas
- 1.5K Switch
- 78 Switch Ideas
- 1.2K Wireless
- 42 Wireless Ideas
- 6.6K Consumer Product
- 261 Service & License
- 406 News and Release
- 87 Security Advisories
- 31 Education Center
- 10 [Campaign] Zyxel Network Detective
- 3.8K FAQ
- 34 Documents
- 34 Nebula Monthly Express
- 85 About Community
- 82 Security Highlight