mirror of
https://git.sr.ht/~hamburghammer/sshlog
synced 2024-12-23 05:27:41 +01:00
Augusto Dwenger J.
c70df10d0d
To have better handling regarding the interface and port to used. This makes the application only use one address at the time, but if I want the application to bind to IPv4 and IPv6 I can spawn two instances or use Docker and its networking to bind it on the host on both addresses.
41 lines
777 B
Desktop File
41 lines
777 B
Desktop File
[Unit]
|
|
Description=SSH Auth Logging
|
|
Requires=network-online.target
|
|
|
|
[Service]
|
|
Type=simple
|
|
Restart=always
|
|
RestartSec=30sec
|
|
# Path to the executable
|
|
ExecStart=/home/user/go/bin/sshlog -a 0.0.0.0:2222
|
|
KillSignal=SIGTERM
|
|
|
|
# Stop trying to restart the service if it restarts too many times in a row
|
|
StartLimitInterval=5min
|
|
StartLimitBurst=4
|
|
|
|
StandardOutput=journal
|
|
StandardError=journal
|
|
StandardInput=null
|
|
|
|
DynamicUser=yes
|
|
|
|
PrivateTmp=true
|
|
PrivateDevices=true
|
|
PrivateMounts=true
|
|
ProtectSystem=full
|
|
#ProtectHome=true
|
|
RestrictNamespaces=true
|
|
InaccessiblePaths=/run /var /etc
|
|
|
|
PrivateUsers=true
|
|
|
|
NoNewPrivileges=true
|
|
ProtectKernelTunables=true
|
|
ProtectKernelModules=true
|
|
ProtectKernelLogs=true
|
|
ProtectControlGroups=true
|
|
MemoryDenyWriteExecute=true
|
|
|
|
[Install]
|
|
WantedBy=multi-user.target
|