mirror of
https://github.com/msfjarvis/server-config
synced 2025-08-14 08:17:01 +05:30
systemd: Configure security options
Signed-off-by: Harsh Shandilya <msfjarvis@gmail.com>
This commit is contained in:
parent
1f8a7183d4
commit
c9b2bf0ad8
4 changed files with 8 additions and 2 deletions
|
@ -12,6 +12,10 @@ User=caddy
|
||||||
Group=caddy
|
Group=caddy
|
||||||
ExecStart=/usr/local/bin/daas
|
ExecStart=/usr/local/bin/daas
|
||||||
Restart=always
|
Restart=always
|
||||||
|
PrivateTmp=true
|
||||||
|
PrivateDevices=true
|
||||||
|
ProtectHome=true
|
||||||
|
ProtectSystem=full
|
||||||
|
|
||||||
[Install]
|
[Install]
|
||||||
WantedBy=multi-user.target
|
WantedBy=multi-user.target
|
||||||
|
|
|
@ -15,6 +15,10 @@ WorkingDirectory=/var/lib/gitea/
|
||||||
ExecStart=/usr/local/bin/gitea web -c /etc/gitea/app.ini
|
ExecStart=/usr/local/bin/gitea web -c /etc/gitea/app.ini
|
||||||
Restart=always
|
Restart=always
|
||||||
Environment=USER=git HOME=/home/git GITEA_WORK_DIR=/var/lib/gitea
|
Environment=USER=git HOME=/home/git GITEA_WORK_DIR=/var/lib/gitea
|
||||||
|
PrivateTmp=true
|
||||||
|
PrivateDevices=true
|
||||||
|
ProtectSystem=full
|
||||||
|
ReadWriteDirectories=/var/lib/gitea
|
||||||
CapabilityBoundingSet=CAP_NET_BIND_SERVICE
|
CapabilityBoundingSet=CAP_NET_BIND_SERVICE
|
||||||
AmbientCapabilities=CAP_NET_BIND_SERVICE
|
AmbientCapabilities=CAP_NET_BIND_SERVICE
|
||||||
|
|
||||||
|
|
|
@ -15,7 +15,6 @@ KillSignal=SIGQUIT
|
||||||
TimeoutStopSec=5s
|
TimeoutStopSec=5s
|
||||||
PrivateTmp=true
|
PrivateTmp=true
|
||||||
PrivateDevices=true
|
PrivateDevices=true
|
||||||
ProtectSystem=full
|
|
||||||
|
|
||||||
[Install]
|
[Install]
|
||||||
WantedBy=multi-user.target
|
WantedBy=multi-user.target
|
||||||
|
|
|
@ -15,7 +15,6 @@ KillSignal=SIGQUIT
|
||||||
TimeoutStopSec=5s
|
TimeoutStopSec=5s
|
||||||
PrivateTmp=true
|
PrivateTmp=true
|
||||||
PrivateDevices=true
|
PrivateDevices=true
|
||||||
ProtectSystem=full
|
|
||||||
|
|
||||||
[Install]
|
[Install]
|
||||||
WantedBy=multi-user.target
|
WantedBy=multi-user.target
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue