diff options
Diffstat (limited to 'meta')
-rw-r--r-- | meta/recipes-connectivity/openssh/openssh/sshd@.service | 4 | ||||
-rw-r--r-- | meta/recipes-connectivity/openssh/openssh/sshdgenkeys.service | 21 |
2 files changed, 19 insertions, 6 deletions
diff --git a/meta/recipes-connectivity/openssh/openssh/sshd@.service b/meta/recipes-connectivity/openssh/openssh/sshd@.service index bb2d68e96a..9d83dfb2bb 100644 --- a/meta/recipes-connectivity/openssh/openssh/sshd@.service +++ b/meta/recipes-connectivity/openssh/openssh/sshd@.service | |||
@@ -4,7 +4,9 @@ Wants=sshdgenkeys.service | |||
4 | After=sshdgenkeys.service | 4 | After=sshdgenkeys.service |
5 | 5 | ||
6 | [Service] | 6 | [Service] |
7 | ExecStart=-@SBINDIR@/sshd -i | 7 | Environment="SSHD_OPTS=" |
8 | EnvironmentFile=-/etc/default/ssh | ||
9 | ExecStart=-@SBINDIR@/sshd -i $SSHD_OPTS | ||
8 | ExecReload=@BASE_BINDIR@/kill -HUP $MAINPID | 10 | ExecReload=@BASE_BINDIR@/kill -HUP $MAINPID |
9 | StandardInput=socket | 11 | StandardInput=socket |
10 | StandardError=syslog | 12 | StandardError=syslog |
diff --git a/meta/recipes-connectivity/openssh/openssh/sshdgenkeys.service b/meta/recipes-connectivity/openssh/openssh/sshdgenkeys.service index d65086fc8a..148e6ad63a 100644 --- a/meta/recipes-connectivity/openssh/openssh/sshdgenkeys.service +++ b/meta/recipes-connectivity/openssh/openssh/sshdgenkeys.service | |||
@@ -1,11 +1,22 @@ | |||
1 | [Unit] | 1 | [Unit] |
2 | Description=OpenSSH Key Generation | 2 | Description=OpenSSH Key Generation |
3 | ConditionPathExists=|!/etc/ssh/ssh_host_rsa_key | 3 | RequiresMountsFor=/var /run |
4 | ConditionPathExists=|!/etc/ssh/ssh_host_dsa_key | 4 | ConditionPathExists=!/var/run/ssh/ssh_host_rsa_key |
5 | ConditionPathExists=|!/etc/ssh/ssh_host_ecdsa_key | 5 | ConditionPathExists=!/var/run/ssh/ssh_host_dsa_key |
6 | ConditionPathExists=|!/etc/ssh/ssh_host_ed25519_key | 6 | ConditionPathExists=!/var/run/ssh/ssh_host_ecdsa_key |
7 | ConditionPathExists=!/var/run/ssh/ssh_host_ed25519_key | ||
8 | ConditionPathExists=!/etc/ssh/ssh_host_rsa_key | ||
9 | ConditionPathExists=!/etc/ssh/ssh_host_dsa_key | ||
10 | ConditionPathExists=!/etc/ssh/ssh_host_ecdsa_key | ||
11 | ConditionPathExists=!/etc/ssh/ssh_host_ed25519_key | ||
7 | 12 | ||
8 | [Service] | 13 | [Service] |
9 | ExecStart=@BINDIR@/ssh-keygen -A | 14 | Environment="SYSCONFDIR=/etc/ssh" |
15 | EnvironmentFile=-/etc/default/ssh | ||
16 | ExecStart=@BASE_BINDIR@/mkdir -p $SYSCONFDIR | ||
17 | ExecStart=@BINDIR@/ssh-keygen -q -f ${SYSCONFDIR}/ssh_host_rsa_key -N '' -t rsa | ||
18 | ExecStart=@BINDIR@/ssh-keygen -q -f ${SYSCONFDIR}/ssh_host_dsa_key -N '' -t dsa | ||
19 | ExecStart=@BINDIR@/ssh-keygen -q -f ${SYSCONFDIR}/ssh_host_ecdsa_key -N '' -t ecdsa | ||
20 | ExecStart=@BINDIR@/ssh-keygen -q -f ${SYSCONFDIR}/ssh_host_ed25519_key -N '' -t ed25519 | ||
10 | Type=oneshot | 21 | Type=oneshot |
11 | RemainAfterExit=yes | 22 | RemainAfterExit=yes |