mirror of
https://github.com/billz/raspap-webgui.git
synced 2025-03-01 10:31:47 +00:00
Update sudoers .env permissions, systemd service user
This commit is contained in:
parent
5d8fed824a
commit
87216bdc02
@ -28,6 +28,9 @@ www-data ALL=(ALL) NOPASSWD:/bin/systemctl stop openvpn-client@client
|
|||||||
www-data ALL=(ALL) NOPASSWD:/bin/systemctl disable openvpn-client@client
|
www-data ALL=(ALL) NOPASSWD:/bin/systemctl disable openvpn-client@client
|
||||||
www-data ALL=(ALL) NOPASSWD:/bin/systemctl start restapi.service
|
www-data ALL=(ALL) NOPASSWD:/bin/systemctl start restapi.service
|
||||||
www-data ALL=(ALL) NOPASSWD:/bin/systemctl stop restapi.service
|
www-data ALL=(ALL) NOPASSWD:/bin/systemctl stop restapi.service
|
||||||
|
www-data ALL=(ALL) NOPASSWD:/bin/systemctl status restapi.service
|
||||||
|
www-data ALL=(ALL) NOPASSWD:/bin/touch /etc/raspap/api/.env
|
||||||
|
www-data ALL=(ALL) NOPASSWD:/bin/mv /tmp/.env /etc/raspap/api/.env
|
||||||
www-data ALL=(ALL) NOPASSWD:/bin/mv /tmp/ovpn/* /etc/openvpn/client/*.conf
|
www-data ALL=(ALL) NOPASSWD:/bin/mv /tmp/ovpn/* /etc/openvpn/client/*.conf
|
||||||
www-data ALL=(ALL) NOPASSWD:/usr/bin/ln -s /etc/openvpn/client/*.conf /etc/openvpn/client/*.conf
|
www-data ALL=(ALL) NOPASSWD:/usr/bin/ln -s /etc/openvpn/client/*.conf /etc/openvpn/client/*.conf
|
||||||
www-data ALL=(ALL) NOPASSWD:/bin/rm /etc/openvpn/client/*.conf
|
www-data ALL=(ALL) NOPASSWD:/bin/rm /etc/openvpn/client/*.conf
|
||||||
|
@ -3,10 +3,11 @@ Description=raspap-restapi
|
|||||||
After=network.target
|
After=network.target
|
||||||
|
|
||||||
[Service]
|
[Service]
|
||||||
User=%i
|
User=pi
|
||||||
WorkingDirectory=/etc/raspap/api
|
WorkingDirectory=/etc/raspap/api
|
||||||
LimitNOFILE=4096
|
LimitNOFILE=4096
|
||||||
ExecStart=/usr/bin/python3 -m uvicorn main:app --host 0.0.0.0 --port 8081 --reload
|
ExecStart=/usr/bin/python3 -m uvicorn main:app --host 0.0.0.0 --port 8081 --reload
|
||||||
|
ExecStop=/bin/kill -HUP ${MAINPID}
|
||||||
Restart=on-failure
|
Restart=on-failure
|
||||||
RestartSec=5s
|
RestartSec=5s
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user