summaryrefslogtreecommitdiffstats
path: root/meta/recipes-core/dropbear
diff options
context:
space:
mode:
Diffstat (limited to 'meta/recipes-core/dropbear')
-rw-r--r--meta/recipes-core/dropbear/dropbear/dropbear@.service3
-rw-r--r--meta/recipes-core/dropbear/dropbear/dropbearkey.service9
2 files changed, 9 insertions, 3 deletions
diff --git a/meta/recipes-core/dropbear/dropbear/dropbear@.service b/meta/recipes-core/dropbear/dropbear/dropbear@.service
index 6fe9942090..b420bcddcb 100644
--- a/meta/recipes-core/dropbear/dropbear/dropbear@.service
+++ b/meta/recipes-core/dropbear/dropbear/dropbear@.service
@@ -4,8 +4,9 @@ Wants=dropbearkey.service
4After=syslog.target dropbearkey.service 4After=syslog.target dropbearkey.service
5 5
6[Service] 6[Service]
7Environment="DROPBEAR_RSAKEY_DIR=/etc/dropbear"
7EnvironmentFile=-/etc/default/dropbear 8EnvironmentFile=-/etc/default/dropbear
8ExecStart=-@SBINDIR@/dropbear -i -r /etc/dropbear/dropbear_rsa_host_key $DROPBEAR_EXTRA_ARGS 9ExecStart=-@SBINDIR@/dropbear -i -r ${DROPBEAR_RSAKEY_DIR}/dropbear_rsa_host_key $DROPBEAR_EXTRA_ARGS
9ExecReload=@BASE_BINDIR@/kill -HUP $MAINPID 10ExecReload=@BASE_BINDIR@/kill -HUP $MAINPID
10StandardInput=socket 11StandardInput=socket
11KillMode=process 12KillMode=process
diff --git a/meta/recipes-core/dropbear/dropbear/dropbearkey.service b/meta/recipes-core/dropbear/dropbear/dropbearkey.service
index ccc21d5cca..c49053d57c 100644
--- a/meta/recipes-core/dropbear/dropbear/dropbearkey.service
+++ b/meta/recipes-core/dropbear/dropbear/dropbearkey.service
@@ -1,8 +1,13 @@
1[Unit] 1[Unit]
2Description=SSH Key Generation 2Description=SSH Key Generation
3ConditionPathExists=|!/etc/dropbear/dropbear_rsa_host_key 3RequiresMountsFor=/var /var/lib
4ConditionPathExists=!/etc/dropbear/dropbear_rsa_host_key
5ConditionPathExists=!/var/lib/dropbear/dropbear_rsa_host_key
4 6
5[Service] 7[Service]
8Environment="DROPBEAR_RSAKEY_DIR=/etc/dropbear"
9EnvironmentFile=-/etc/default/dropbear
6Type=oneshot 10Type=oneshot
7ExecStart=@SBINDIR@/dropbearkey -t rsa -f /etc/dropbear/dropbear_rsa_host_key 11ExecStart=@BASE_BINDIR@/mkdir -p ${DROPBEAR_RSAKEY_DIR}
12ExecStart=@SBINDIR@/dropbearkey -t rsa -f ${DROPBEAR_RSAKEY_DIR}/dropbear_rsa_host_key
8RemainAfterExit=yes 13RemainAfterExit=yes