diff --git a/playbooks/groups/sundries.yml b/playbooks/groups/sundries.yml index c4f70c4d8f..e27c115bf8 100644 --- a/playbooks/groups/sundries.yml +++ b/playbooks/groups/sundries.yml @@ -29,7 +29,7 @@ - role: easyfix/gather when: master_sundries_node|bool - role: regindexer/build - when: master_sundries_node|bool + when: master_sundries_node|bool and env != "staging" - role: bz_review_report when: master_sundries_node|bool and env != "staging" - rsyncd @@ -69,6 +69,11 @@ mnt_dir: '/srv/web/review-stats' nfs_src_dir: 'openshift_{{ env_short }}_reviewstats' mount_stg: true + - role: nfs/client + mnt_dir: '/srv/web/registry-index' + nfs_src_dir: '/flatpak-indexer-storage{{ env_short }}' + mount_stg: true + pre_tasks: - import_tasks: "{{ tasks_path }}/yumrepos.yml" diff --git a/roles/fedora-web/registry/files/cron-sync-registry-signatures b/roles/fedora-web/registry/files/cron-sync-registry-signatures deleted file mode 100644 index 7956c9a415..0000000000 --- a/roles/fedora-web/registry/files/cron-sync-registry-signatures +++ /dev/null @@ -1 +0,0 @@ -30 * * * * root /usr/bin/rsync --delete -a --no-owner --no-group sundries01::registry-signatures/ /srv/web/registry-signatures/ diff --git a/roles/fedora-web/registry/tasks/main.yml b/roles/fedora-web/registry/tasks/main.yml index d8756bdc23..c5895990e4 100644 --- a/roles/fedora-web/registry/tasks/main.yml +++ b/roles/fedora-web/registry/tasks/main.yml @@ -4,18 +4,6 @@ - fedora-web when: env != 'staging' -- name: make registry-signatures dir - file: state=directory path=/srv/web/registry-signatures owner=apache group=apache mode=2775 setype=httpd_sys_content_t seuser=system_u - tags: - - fedora-web - when: env == 'staging' - -- name: make registry-index dir - file: state=directory path=/srv/web/registry-index owner=apache group=sysadmin-releng mode=755 setype=httpd_sys_content_t seuser=system_u - tags: - - fedora-web - when: env != 'staging' - - name: make registry-index dir file: state=directory path=/srv/web/registry-index owner=apache group=apache mode=755 setype=httpd_sys_content_t seuser=system_u tags: @@ -31,20 +19,8 @@ - fedora-web - fedora-web/registry -#- name: Copy in the sync-registry-signatures cronjob -# copy: src=cron-sync-registry-signatures dest=/etc/cron.d/sync-registry-signatures -# tags: -# - fedora-web -# - fedora-web/registry - -- name: Temporarily disable the registry-signatures cronjob - file: path=/etc/cron.d/sync-registry-signatures state=absent - tags: - - fedora-web - - fedora-web/registry - - name: Copy in the sync-registry-index cronjob - copy: src=cron-sync-registry-index dest=/etc/cron.d/sync-registry-index + template: src=cron-sync-registry-index dest=/etc/cron.d/sync-registry-index tags: - fedora-web - fedora-web/registry diff --git a/roles/fedora-web/registry/files/cron-sync-registry-index b/roles/fedora-web/registry/templates/cron-sync-registry-index similarity index 90% rename from roles/fedora-web/registry/files/cron-sync-registry-index rename to roles/fedora-web/registry/templates/cron-sync-registry-index index 2c73156c7b..1862bc6b44 100644 --- a/roles/fedora-web/registry/files/cron-sync-registry-index +++ b/roles/fedora-web/registry/templates/cron-sync-registry-index @@ -1,3 +1,5 @@ 30 * * * * root /usr/bin/rsync -a --no-owner --no-group sundries01::registry-index/ /srv/web/registry-index/ +{% if env != 'staging' %} 31 * * * * root /usr/bin/rsync --delete -a --no-owner --no-group sundries01::regindexer/index/ /srv/web/registry-index/index/ 32 * * * * root /usr/bin/rsync --delete -a --no-owner --no-group sundries01::regindexer/icons/ /srv/web/registry-index/icons/ +{% endif %} diff --git a/roles/rsyncd/files/rsyncd.conf.sundries-stg b/roles/rsyncd/files/rsyncd.conf.sundries-stg index 05d1f33cb8..b1265f0bfb 100644 --- a/roles/rsyncd/files/rsyncd.conf.sundries-stg +++ b/roles/rsyncd/files/rsyncd.conf.sundries-stg @@ -192,7 +192,7 @@ hosts allow = 10.5.126.0/255.255.255.0 192.168.0.0/255.255.0.0 10.5.128.0/255.25 [registry-index] comment = registry-index -path = /var/lib/reg-server/static/ +path = /srv/web/registry-index uid = root gid = root read only = yes