20 lines
606 B
Desktop File
20 lines
606 B
Desktop File
[Unit]
|
|
Description=OpenSSH server daemon
|
|
ConditionKernelCommandLine=|ssh
|
|
ConditionPathExists=|/storage/.cache/services/sshd.conf
|
|
|
|
[Service]
|
|
Restart=on-failure
|
|
EnvironmentFile=-/storage/.cache/services/sshd.conf
|
|
ExecStartPre=-/bin/sh -c 'mkdir -p /storage/.cache/ssh'
|
|
ExecStartPre=/usr/bin/ssh-keygen -A
|
|
ExecStartPre=-/bin/sh -c 'chmod 600 /storage/.cache/ssh/ssh_host_*'
|
|
ExecStartPre=-/bin/sh -c 'chmod 644 /storage/.cache/ssh/ssh_host_*.pub'
|
|
ExecStart=/usr/sbin/sshd -D $SSH_ARGS
|
|
ExecReload=/bin/kill -HUP $MAINPID
|
|
TimeoutStopSec=1s
|
|
RestartSec=2
|
|
StartLimitInterval=0
|
|
|
|
[Install]
|
|
WantedBy=multi-user.target
|