]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph-build.git/commitdiff
restart ssh depending on distro
authorAlfredo Deza <adeza@redhat.com>
Thu, 22 Oct 2015 15:06:12 +0000 (11:06 -0400)
committerAlfredo Deza <adeza@redhat.com>
Thu, 22 Oct 2015 15:06:39 +0000 (11:06 -0400)
Signed-off-by: Alfredo Deza <adeza@redhat.com>
ansible/init.yml

index 922f7780e16574a9e0912ce717cdc52039432a6a..10399b108c9885f136a6faf0767bec5a3f64b905 100644 (file)
@@ -6,7 +6,7 @@
 # be publicly accessible.
 
 - hosts: all
-  user: centos
+  user: admin
   sudo: true
   tasks:
 
     #  command: firewall-cmd --add-port 2222/tcp --permanent
 
     # Example action to start service httpd, if not running
+    - name: restart ssh
+      service: name=ssh state=restarted
+      when: ansible_pkg_mgr  == "apt"
+
     - name: restart sshd
       service: name=sshd state=restarted
+      when: ansible_pkg_mgr  == "yum"