| |
@@ -1,3 +1,4 @@
|
| |
+ ---
|
| |
- name: Install needed packages
|
| |
package:
|
| |
state: present
|
| |
@@ -22,72 +23,66 @@
|
| |
- fedora-web
|
| |
|
| |
- name: Create file to indicate we want live fedimg data
|
| |
- copy: dest=/var/fedora_websites_live_fedimg
|
| |
- content="Indicator file"
|
| |
+ copy:
|
| |
+ dest: /var/fedora_websites_live_fedimg
|
| |
+ content: "Indicator file"
|
| |
tags:
|
| |
- fedora-web
|
| |
|
| |
- name: Create directories
|
| |
- file: state=directory
|
| |
- path=/srv/web/{{item}}
|
| |
- owner=apache group=apache mode=0755
|
| |
- setype=httpd_sys_content_t seuser=system_u
|
| |
+ file:
|
| |
+ state: directory
|
| |
+ path: /srv/web/{{ item }}
|
| |
+ owner: apache
|
| |
+ group: apache
|
| |
+ mode: '0755'
|
| |
+ setype: httpd_sys_content_t
|
| |
+ seuser: system_u
|
| |
with_items:
|
| |
- fedora-web
|
| |
- fedoraproject.org
|
| |
- - spins.fedoraproject.org
|
| |
- talk.fedoraproject.org
|
| |
- - start.fedoraproject.org
|
| |
- mirrors.fedoraproject.org
|
| |
- - fedoracommunity.org
|
| |
- - flocktofedora.org
|
| |
- - arm.fedoraproject.org
|
| |
- iot.fedoraproject.org
|
| |
- - labs.fedoraproject.org
|
| |
tags:
|
| |
- fedora-web
|
| |
|
| |
- name: make fmw dir
|
| |
- file: state=directory path=/srv/web/fmw owner=apache group=sysadmin-releng mode=2775 setype=httpd_sys_content_t seuser=system_u
|
| |
+ file:
|
| |
+ state: directory
|
| |
+ path: /srv/web/fmw
|
| |
+ owner: apache
|
| |
+ group: sysadmin-releng
|
| |
+ mode: '2775'
|
| |
+ setype: httpd_sys_content_t
|
| |
+ seuser: system_u
|
| |
tags:
|
| |
- fedora-web
|
| |
when: env != 'staging'
|
| |
|
| |
- name: make fmw dir
|
| |
- file: state=directory path=/srv/web/fmw owner=apache group=apache mode=2775 setype=httpd_sys_content_t seuser=system_u
|
| |
+ file:
|
| |
+ state: directory
|
| |
+ path: /srv/web/fmw
|
| |
+ owner: apache
|
| |
+ group: apache
|
| |
+ mode: '2775'
|
| |
+ setype: httpd_sys_content_t
|
| |
+ seuser: system_u
|
| |
tags:
|
| |
- fedora-web
|
| |
when: env == 'staging'
|
| |
|
| |
- - name: Copy syncStatic script (stg)
|
| |
- when: env == "staging"
|
| |
- copy: >
|
| |
- src=syncStatic.stg.sh dest=/usr/local/bin/syncStatic owner=root group=root
|
| |
- mode=0755
|
| |
- tags:
|
| |
- - fedora-web
|
| |
-
|
| |
- - name: Copy syncStatic script (prod)
|
| |
- when: env == "production"
|
| |
- copy: >
|
| |
- src=syncStatic.sh dest=/usr/local/bin/syncStatic owner=root group=root
|
| |
- mode=0755
|
| |
- tags:
|
| |
- - fedora-web
|
| |
-
|
| |
- - name: Install the syncStatic and syncTranslations cronjobs
|
| |
- copy: >
|
| |
- src={{item}}.cron dest=/etc/cron.d/{{item}}.cron
|
| |
- owner=root group=root mode=0644
|
| |
- with_items:
|
| |
- - syncStatic
|
| |
+ - name: Remove the syncTranslations cronjob
|
| |
+ file:
|
| |
+ path: /etc/cron.d/syncTranslations.cron
|
| |
+ state: absent
|
| |
tags:
|
| |
- - fedora-web
|
| |
- cron
|
| |
|
| |
- - name: Remove the syncTranslations cronjob
|
| |
- file:
|
| |
- path: /etc/cron.d/syncTranslations.cron
|
| |
+ - name: Remove the syncStatic cronjob
|
| |
+ file:
|
| |
+ path: /etc/cron.d/syncStatic.cron
|
| |
state: absent
|
| |
tags:
|
| |
- cron
|
| |
Depends on: https://pagure.io/fedora-infra/ansible/pull-request/847
This is the second part of the move.
It removes the cron job from sundries, and reconfigures rsyncd to use the new websites location.