Add systemd unit files for the AUR sshd

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
This commit is contained in:
Lukas Fleischer 2014-12-29 13:28:08 +01:00
parent 176014a5d7
commit 4fc1c2c10c
3 changed files with 19 additions and 2 deletions

View file

@ -37,6 +37,9 @@ Setup on Arch Linux
# useradd -U -d /srv/http/aur -c 'AUR user' aur # useradd -U -d /srv/http/aur -c 'AUR user' aur
# chown aur:aur /srv/http/aur/.ssh/ # chown aur:aur /srv/http/aur/.ssh/
8) Run the sshd as the new user. 8) Add, enable and start systemd unit files for the new sshd:
$ /srv/http/aur/openssh/sshd -f /srv/http/aur/.ssh/sshd_config # cp /srv/http/aur/conf/aur-sshd.socket /etc/systemd/system/
# cp /srv/http/aur/conf/aur-sshd@.service /etc/systemd/system/
# systemctl enable aur-sshd.socket
# systemctl start aur-sshd.socket

6
conf/aur-sshd.socket Normal file
View file

@ -0,0 +1,6 @@
[Socket]
ListenStream=2222
Accept=yes
[Install]
WantedBy=sockets.target

8
conf/aur-sshd@.service Normal file
View file

@ -0,0 +1,8 @@
[Unit]
Description=AUR OpenSSH Per-Connection Daemon
[Service]
ExecStart=-/srv/http/aur/openssh/sshd -i -f /srv/http/aur/.ssh/sshd_config
User=aur
StandardInput=socket
StandardError=syslog