Blame SOURCES/sshd-example.diff

0c1b9b
diff --git a/README.md b/README.md
0c1b9b
index 676ad72..dc06d85 100644
0c1b9b
--- a/README.md
0c1b9b
+++ b/README.md
0c1b9b
@@ -190,7 +190,7 @@ defaults. This is useful if the role is used in deployment stage to make sure
0c1b9b
 the service is able to start on the first attempt. To disable this check, set
0c1b9b
 this to empty list.
0c1b9b
 
0c1b9b
-* `sshd_hostkey_owner`, `sshd_hostkey_group`, `sshd_hostkey_group`
0c1b9b
+* `sshd_hostkey_owner`, `sshd_hostkey_group`, `sshd_hostkey_mode`
0c1b9b
 
0c1b9b
 Use these variables to set the ownership and permissions for the host keys from
0c1b9b
 the above list.
0c1b9b
@@ -273,6 +273,8 @@ for example:
0c1b9b
             X11Forwarding: yes
0c1b9b
 ```
0c1b9b
 
0c1b9b
+More example playbooks can be found in [`examples/`](examples/) directory.
0c1b9b
+
0c1b9b
 Template Generation
0c1b9b
 -------------------
0c1b9b
 
0c1b9b
diff --git a/examples/example-root-login.yml b/examples/example-root-login.yml
0c1b9b
new file mode 100644
0c1b9b
index 0000000..156e629
0c1b9b
--- /dev/null
0c1b9b
+++ b/examples/example-root-login.yml
0c1b9b
@@ -0,0 +1,15 @@
0c1b9b
+---
0c1b9b
+- hosts: all
0c1b9b
+  tasks:
0c1b9b
+  - name: Configure sshd to prevent root and password login except from particular subnet
0c1b9b
+    include_role:
0c1b9b
+      name: ansible-sshd
0c1b9b
+    vars:
0c1b9b
+      sshd:
0c1b9b
+        # root login and password login is enabled only from a particular subnet
0c1b9b
+        PermitRootLogin: no
0c1b9b
+        PasswordAuthentication: no
0c1b9b
+        Match:
0c1b9b
+        - Condition: "Address 192.0.2.0/24"
0c1b9b
+          PermitRootLogin: yes
0c1b9b
+          PasswordAuthentication: yes