mirror of
https://github.com/gogs/gogs.git
synced 2025-05-28 10:12:37 +00:00
scripts: add NoNewPrivileges=true to systemd unit file (#5381)
Also add comment about unsupported options in different systemd versions.
This commit is contained in:
parent
4c1a479a60
commit
3c227af508
@ -18,10 +18,13 @@ WorkingDirectory=/home/git/gogs
|
||||
ExecStart=/home/git/gogs/gogs web
|
||||
Restart=always
|
||||
Environment=USER=git HOME=/home/git
|
||||
# Hardening
|
||||
|
||||
# Some distributions may not support these hardening directives. If you cannot start the service due
|
||||
# to an unknown option, comment out the ones not supported by your version of systemd.
|
||||
ProtectSystem=full
|
||||
PrivateDevices=yes
|
||||
PrivateTmp=yes
|
||||
NoNewPrivileges=true
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
|
Loading…
x
Reference in New Issue
Block a user