mirror of
https://github.com/fankes/beszel.git
synced 2025-10-19 01:39:34 +08:00
agent-install: add security options to systemd unit file
This commit is contained in:
@@ -470,8 +470,24 @@ Environment="KEY=$KEY"
|
||||
# Environment="EXTRA_FILESYSTEMS=sdb"
|
||||
ExecStart=/opt/beszel-agent/beszel-agent
|
||||
User=beszel
|
||||
Restart=always
|
||||
Restart=on-failure
|
||||
RestartSec=5
|
||||
StateDirectory=beszel-agent
|
||||
|
||||
# Security/sandboxing settings
|
||||
KeyringMode=private
|
||||
LockPersonality=yes
|
||||
NoNewPrivileges=yes
|
||||
PrivateTmp=yes
|
||||
ProtectClock=yes
|
||||
ProtectHome=read-only
|
||||
ProtectHostname=yes
|
||||
ProtectKernelLogs=yes
|
||||
ProtectKernelTunables=yes
|
||||
ProtectSystem=strict
|
||||
RemoveIPC=yes
|
||||
RestrictSUIDSGID=true
|
||||
SystemCallArchitectures=native
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
|
Reference in New Issue
Block a user