aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--roles/ssh/handlers/main.yml2
-rw-r--r--roles/ssh/vars/Debian.yml3
-rw-r--r--roles/ssh/vars/OpenBSD.yml3
3 files changed, 7 insertions, 1 deletions
diff --git a/roles/ssh/handlers/main.yml b/roles/ssh/handlers/main.yml
index 1150f2e..f56bca4 100644
--- a/roles/ssh/handlers/main.yml
+++ b/roles/ssh/handlers/main.yml
@@ -1,3 +1,3 @@
---
- name: Restart SSH
- service: name=ssh state=restarted
+ service: name={{ services.ssh }} state=restarted
diff --git a/roles/ssh/vars/Debian.yml b/roles/ssh/vars/Debian.yml
index 61c7205..95ae005 100644
--- a/roles/ssh/vars/Debian.yml
+++ b/roles/ssh/vars/Debian.yml
@@ -9,5 +9,8 @@ packages:
- openssh-blacklist-extra
- openssh-known-hosts
+services:
+ ssh: ssh
+
ssh:
allow_root_user: without-password
diff --git a/roles/ssh/vars/OpenBSD.yml b/roles/ssh/vars/OpenBSD.yml
index 19130aa..afdba33 100644
--- a/roles/ssh/vars/OpenBSD.yml
+++ b/roles/ssh/vars/OpenBSD.yml
@@ -2,5 +2,8 @@
packages:
ssh: []
+services:
+ ssh: sshd
+
ssh:
allow_root_user: "no"