@cmm11 I added this file /usr/lib/systemd/system/flexget.service
with the intention of reducing the running permissions for users who use flexget-webui. Users using the webui can directly run command within the webui. If you have to run these commands from the command line, traditional su
cannot do it because the shell of the flexget
user is /usr/bin/nologin
and login is prohibited.
-
You can run
sudo -u flexget flexget -c /var/lib/flexget/config.yml execute --task task_name
-
Or You can use the gosu that I just packaged to implement:
sudo gosu <user>:<group> <command>
, for example:sudo gosu flexget:flexget flexget -c /var/lib/flexget/config.yml execute --task task_name
.
If you are using /usr/lib/systemd/system/flexget.service
, you can add a alias in your shell rc file: alias flexget="sudo -u flexget /usr/bin/flexget -c /var/lib/flexget/config.yml
or alias flexget="sudo gosu flexget:flexget /usr/bin/flexget -c /var/lib/flexget/config.yml"
.
Pinned Comments
evine commented on 2024-10-22 00:36 (UTC) (edited on 2024-10-26 00:26 (UTC) by evine)
@cmm11 I added this file
/usr/lib/systemd/system/flexget.service
with the intention of reducing the running permissions for users who use flexget-webui. Users using the webui can directly run command within the webui. If you have to run these commands from the command line, traditionalsu
cannot do it because the shell of theflexget
user is/usr/bin/nologin
and login is prohibited.You can run
sudo -u flexget flexget -c /var/lib/flexget/config.yml execute --task task_name
Or You can use the gosu that I just packaged to implement:
sudo gosu <user>:<group> <command>
, for example:sudo gosu flexget:flexget flexget -c /var/lib/flexget/config.yml execute --task task_name
.If you are using
/usr/lib/systemd/system/flexget.service
, you can add a alias in your shell rc file:alias flexget="sudo -u flexget /usr/bin/flexget -c /var/lib/flexget/config.yml
oralias flexget="sudo gosu flexget:flexget /usr/bin/flexget -c /var/lib/flexget/config.yml"
.evine commented on 2024-10-19 04:50 (UTC) (edited on 2024-10-22 01:53 (UTC) by evine)
After taking over Flexget, I had
flexget-webui
andflexget-webui-v1
inoptdepends
, you can install and enable webui if you need. When using webui, it is recommended to use/usr/lib/systemd/system/flexget.service
I have newly added./usr/lib/systemd/system/flexget.service
to run as a system user, the original methods that run as normal user still exists:/usr/lib/systemd/system/flexget@.service
and/usr/lib/systemd/user/flexget.service
.If upgrade fail, you should remove old
flexget
first, and reinstall.