DietPi-Software | SABnzbd: Switch to user "dietpi"?

Created on 24 Oct 2018  ·  6Comments  ·  Source: MichaIng/DietPi

Ref: https://dietpi.com/phpbb/viewtopic.php?f=11&t=5175

Did we forget it or was there a reason to still run it as root?

Current systemd unit:
https://github.com/Fourdee/DietPi/blob/dev/dietpi/dietpi-software#L11319-L11329

cat << _EOF_ > /etc/systemd/system/sabnzbd.service
[Unit]
Description=sabnzbd DietPi
[Service]
Type=simple
ExecStart=/usr/bin/python /etc/sabnzbd/SABnzbd.py -f /etc/sabnzbd/sabnzbd.ini
[Install]
WantedBy=multi-user.target
_EOF_
Enhancement Question Via Forum

All 6 comments

@MichaIng

Looks like it got missed 👍

Will make change, test and send commit if passes.

  • 🈯️ Install + GUI tests passed.
  • Just need to test actual nzb use.

@Fourdee
Is there a possibility to force umask=0002 or 0007 as well, so other media software (+network shares/drives) have write access as well?

root@DietPi:~# ls -lha /mnt/dietpi_userdata/downloads/complete/
total 12K
drwxr-xr-x 3 sabnzbd dietpi 4.0K Oct 24 14:59 .
drwxrwxr-x 6 dietpi  dietpi 4.0K Oct 24 14:59 ..
drwxr-xr-x 2 sabnzbd dietpi 4.0K Oct 24 14:59 18081905 test.nfo

@MichaIng

mask

Unable to find any entries matching 'mask' in /etc/sabnzbd/sabnzbd.ini, or in GUI pages


?

permissions = ""

https://sabnzbd.org/wiki/advanced/unix-permissions

G_CONFIG_INJECT 'permissions =' 'permissions = "0775"' /etc/sabnzbd/sabnzbd.ini

download nzb

  • 🈯️
root@DietPi:~# ls -lha /mnt/dietpi_userdata/downloads/complete/                 total 20K
drwxrwxrwx 5 sabnzbd dietpi 4.0K Oct 24 15:11 .
drwxrwxrwx 6 dietpi  dietpi 4.0K Oct 24 14:59 ..
drwxrwxr-x 2 sabnzbd dietpi 4.0K Oct 24 15:11 test.rar

so other media software has write access as well?

@MichaIng

done 775 for now, allows group r/w under dietpi, think we need 777?

777 Not required. Tested samba removal fine.

Was this page helpful?
0 / 5 - 0 ratings