]> git.apps.os.sepia.ceph.com Git - ceph-build.git/commitdiff
move the init module to the top level
authorAlfredo Deza <adeza@redhat.com>
Thu, 9 Jul 2015 13:17:57 +0000 (09:17 -0400)
committerAlfredo Deza <adeza@redhat.com>
Fri, 17 Jul 2015 21:23:27 +0000 (17:23 -0400)
Signed-off-by: Alfredo Deza <adeza@redhat.com>
ansible/init.yml [new file with mode: 0644]
ansible/master/init.yml [deleted file]

diff --git a/ansible/init.yml b/ansible/init.yml
new file mode 100644 (file)
index 0000000..e5d2d6b
--- /dev/null
@@ -0,0 +1,43 @@
+---
+
+- hosts: master
+  user: centos
+  sudo: true
+  tasks:
+
+    - name: uncomment SSH port
+      lineinfile:
+        dest: /etc/ssh/sshd_config
+        regexp: '^#Port '
+        line: 'Port 2222'
+        backrefs: yes
+
+    - name: change default port from 22 if set
+      lineinfile:
+        dest: /etc/ssh/sshd_config
+        regexp: '^Port '
+        line: 'Port 2222'
+        backrefs: yes
+
+    # this requires the firewalld module that
+    # I couldn't get to work. It exists in the extras modules
+    #- name: enable the port in the firewall
+    #  firewalld:
+    #    port: 2222/tcp
+    #    permanent: true
+    #    state: enabled
+
+    # this is far from ideal, we ignore errors because we can't
+    # condition this if the port was already opened
+    - name: tell selinux that ssh uses a new port
+      command: semanage port -a -t ssh_port_t -p tcp 2222
+      ignore_errors: yes
+
+    # The CentOS Wiki says this should be run but I couldn't find
+    # a firewall-cmd in the remote CentOS 7 box
+    #- name: configure firewall to add new port
+    #  command: firewall-cmd --add-port 2222/tcp --permanent
+
+    # Example action to start service httpd, if not running
+    - name: restart sshd
+      service: name=sshd state=restarted
diff --git a/ansible/master/init.yml b/ansible/master/init.yml
deleted file mode 100644 (file)
index e5d2d6b..0000000
+++ /dev/null
@@ -1,43 +0,0 @@
----
-
-- hosts: master
-  user: centos
-  sudo: true
-  tasks:
-
-    - name: uncomment SSH port
-      lineinfile:
-        dest: /etc/ssh/sshd_config
-        regexp: '^#Port '
-        line: 'Port 2222'
-        backrefs: yes
-
-    - name: change default port from 22 if set
-      lineinfile:
-        dest: /etc/ssh/sshd_config
-        regexp: '^Port '
-        line: 'Port 2222'
-        backrefs: yes
-
-    # this requires the firewalld module that
-    # I couldn't get to work. It exists in the extras modules
-    #- name: enable the port in the firewall
-    #  firewalld:
-    #    port: 2222/tcp
-    #    permanent: true
-    #    state: enabled
-
-    # this is far from ideal, we ignore errors because we can't
-    # condition this if the port was already opened
-    - name: tell selinux that ssh uses a new port
-      command: semanage port -a -t ssh_port_t -p tcp 2222
-      ignore_errors: yes
-
-    # The CentOS Wiki says this should be run but I couldn't find
-    # a firewall-cmd in the remote CentOS 7 box
-    #- name: configure firewall to add new port
-    #  command: firewall-cmd --add-port 2222/tcp --permanent
-
-    # Example action to start service httpd, if not running
-    - name: restart sshd
-      service: name=sshd state=restarted