From 0e6f1e539e1f19950e999191b436999518658f87 Mon Sep 17 00:00:00 2001 From: s0dy Date: Sun, 18 Nov 2018 16:47:35 +0100 Subject: [PATCH] ansible-ci.yml --- .ansible-ci.yml | 5 ++--- ops/ansible/httpd-centos.yml | 11 ++--------- 2 files changed, 4 insertions(+), 12 deletions(-) diff --git a/.ansible-ci.yml b/.ansible-ci.yml index e19c16a..5fb3668 100644 --- a/.ansible-ci.yml +++ b/.ansible-ci.yml @@ -2,7 +2,6 @@ - hosts: hifive become: yes become_user: root - #become_user: root tasks: - name: Copy all files to web server @@ -19,8 +18,8 @@ group: apache recurse: yes - - name: return motd to registered var + - name: Change file chmod 640 command: find /var/www/html -type f -exec chmod 640 {} \; - - name: return motd to registered var + - name: Change directory chmod 750 command: find /var/www/html -type d -exec chmod 750 {} \; \ No newline at end of file diff --git a/ops/ansible/httpd-centos.yml b/ops/ansible/httpd-centos.yml index 2037e90..86d2e9e 100644 --- a/ops/ansible/httpd-centos.yml +++ b/ops/ansible/httpd-centos.yml @@ -20,19 +20,12 @@ enabled: yes masked: no - - name: Permissions /etc/httpd - file: - path: /etc/httpd - owner: apache - group: apache - recurse: yes - - name: Change file ownership, group and mode file: path: /var/www - owner: apache + owner: root group: apache - mode: "u=r,g=r,o=r" + mode: 0750 recurse: yes - name: Install python-passlib