From 57ad832a4a92c858ce868fd5c2d3fbb4cde49610 Mon Sep 17 00:00:00 2001 From: Pierre-Yves Chibon Date: Mon, 25 May 2020 22:53:46 +0200 Subject: [PATCH 1/3] pkgs: strings should have quotes Signed-off-by: Pierre-Yves Chibon --- playbooks/groups/pkgs.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/playbooks/groups/pkgs.yml b/playbooks/groups/pkgs.yml index 1bcb402c92..5b37f3ea4d 100644 --- a/playbooks/groups/pkgs.yml +++ b/playbooks/groups/pkgs.yml @@ -62,7 +62,7 @@ - /srv/web/infra/ansible/vars/{{ ansible_distribution }}.yml roles: - - { role: gitolite/base, when: env != "staging" and datacenter != iad2} + - { role: gitolite/base, when: env != "staging" and datacenter != "iad2"} - gitolite/check_fedmsg_hooks - { role: git/make_checkout_seed, when: env != "staging" } - git/hooks From bb7accc22960bd9e0ca963e87da17ef2712be24a Mon Sep 17 00:00:00 2001 From: Kevin Fenzi Date: Mon, 25 May 2020 14:07:30 -0700 Subject: [PATCH 2/3] iad2: add sign-bridge01.iad2 and mbs-frontend01/backend01.iad2 Signed-off-by: Kevin Fenzi --- .../host_vars/mbs-backend01.iad2.fedoraproject.org | 13 +++++++++++++ .../host_vars/mbs-frontend01.iad2.fedoraproject.org | 13 +++++++++++++ .../host_vars/sign-bridge01.iad2.fedoraproject.org | 12 ++++++++++++ inventory/inventory | 6 ++++++ 4 files changed, 44 insertions(+) create mode 100644 inventory/host_vars/mbs-backend01.iad2.fedoraproject.org create mode 100644 inventory/host_vars/mbs-frontend01.iad2.fedoraproject.org create mode 100644 inventory/host_vars/sign-bridge01.iad2.fedoraproject.org diff --git a/inventory/host_vars/mbs-backend01.iad2.fedoraproject.org b/inventory/host_vars/mbs-backend01.iad2.fedoraproject.org new file mode 100644 index 0000000000..f92dcc9c88 --- /dev/null +++ b/inventory/host_vars/mbs-backend01.iad2.fedoraproject.org @@ -0,0 +1,13 @@ +--- +nm: 255.255.255.0 +gw: 10.3.169.254 +dns: 10.3.163.33 + +ks_url: http://10.3.163.35/repo/rhel/ks/kvm-rhel-7-iad2 +ks_repo: http://10.3.163.35/repo/rhel/RHEL7-x86_64/ + +eth0_ip: 10.3.169.108 + +volgroup: /dev/vg_guests +vmhost: bvmhost-x86-03.iad2.fedoraproject.org +datacenter: iad2 diff --git a/inventory/host_vars/mbs-frontend01.iad2.fedoraproject.org b/inventory/host_vars/mbs-frontend01.iad2.fedoraproject.org new file mode 100644 index 0000000000..77b9542fd2 --- /dev/null +++ b/inventory/host_vars/mbs-frontend01.iad2.fedoraproject.org @@ -0,0 +1,13 @@ +--- +nm: 255.255.255.0 +gw: 10.3.169.254 +dns: 10.3.163.33 + +ks_url: http://10.3.163.35/repo/rhel/ks/kvm-rhel-7 +ks_repo: http://10.3.163.35/repo/rhel/RHEL7-x86_64/ + +eth0_ip: 10.3.169.109 + +volgroup: /dev/vg_guests +vmhost: bvmhost-x86-04.iad2.fedoraproject.org +datacenter: iad2 diff --git a/inventory/host_vars/sign-bridge01.iad2.fedoraproject.org b/inventory/host_vars/sign-bridge01.iad2.fedoraproject.org new file mode 100644 index 0000000000..1c7b52bea8 --- /dev/null +++ b/inventory/host_vars/sign-bridge01.iad2.fedoraproject.org @@ -0,0 +1,12 @@ +--- +nm: 255.255.255.0 +gw: 10.3.169.254 +dns: 10.3.163.33 + +ks_url: http://10.3.163.35/repo/rhel/ks/kvm-rhel-8-iad2 +ks_repo: http://10.3.163.35/repo/rhel/RHEL8-x86_64/ +volgroup: /dev/vg_guests +vmhost: bvmhost-x86-03.iad2.fedoraproject.org +datacenter: iad2 + +eth0_ip: 10.3.169.120 diff --git a/inventory/inventory b/inventory/inventory index 55fdf63e58..05f3f2257c 100644 --- a/inventory/inventory +++ b/inventory/inventory @@ -170,6 +170,7 @@ mailman01.stg.phx2.fedoraproject.org [mbs_frontend] mbs-frontend01.phx2.fedoraproject.org +mbs-frontend01.iad2.fedoraproject.org mbs-frontend02.phx2.fedoraproject.org [mbs_frontend_stg] @@ -178,6 +179,7 @@ mbs-frontend02.stg.phx2.fedoraproject.org [mbs_backend] mbs-backend01.phx2.fedoraproject.org +mbs-backend01.iad2.fedoraproject.org [mbs_backend_stg] mbs-backend01.stg.phx2.fedoraproject.org @@ -199,6 +201,7 @@ bodhi-backend01.stg.phx2.fedoraproject.org [sign_bridge] sign-bridge01.phx2.fedoraproject.org +sign-bridge01.iad2.fedoraproject.org sign-bridge01.stg.phx2.fedoraproject.org # # sign vault servers don't listen to ssh by default. @@ -1314,6 +1317,8 @@ kojipkgs01.iad2.fedoraproject.org kojipkgs02.iad2.fedoraproject.org log01.iad2.fedoraproject.org loopabull01.iad2.fedoraproject.org +mbs-frontend01.iad2.fedoraproject.org +mbs-backend01.iad2.fedoraproject.org memcached01.iad2.fedoraproject.org mm-frontend01.iad2.fedoraproject.org mm-frontend-checkin01.iad2.fedoraproject.org @@ -1347,6 +1352,7 @@ rabbitmq02.iad2.fedoraproject.org rabbitmq03.iad2.fedoraproject.org compose-rawhide01.iad2.fedoraproject.org secondary01.iad2.fedoraproject.org +sign-bridge01.iad2.fedoraproject.org sundries01.iad2.fedoraproject.org tang01.iad2.fedoraproject.org tang02.iad2.fedoraproject.org From e0ed6697f4e5c7b9d2877497571cc80bfc26c4bb Mon Sep 17 00:00:00 2001 From: Pierre-Yves Chibon Date: Mon, 25 May 2020 23:10:07 +0200 Subject: [PATCH 3/3] distgit: make the iad2 host closer to the current staging and different from phx2 Signed-off-by: Pierre-Yves Chibon --- roles/distgit/pagure/tasks/main.yml | 26 +++++++++--------- roles/distgit/tasks/main.yml | 42 ++++++++++++++--------------- roles/git/hooks/tasks/main.yml | 4 +-- 3 files changed, 36 insertions(+), 36 deletions(-) diff --git a/roles/distgit/pagure/tasks/main.yml b/roles/distgit/pagure/tasks/main.yml index 1c9ad0ba66..35d71d71fd 100644 --- a/roles/distgit/pagure/tasks/main.yml +++ b/roles/distgit/pagure/tasks/main.yml @@ -14,7 +14,7 @@ - libsemanage-python - python-fedora-flask - pagure-dist-git - when: env != "staging" + when: env != "staging" and datacenter != "iad2" tags: - pagure - packages @@ -32,7 +32,7 @@ - python3-libsemanage - python3-fedora-flask - pagure-dist-git - when: env == "staging" + when: env == "staging" or datacenter == "iad2" tags: - pagure - packages @@ -86,7 +86,7 @@ etype: group permissions: r state: present - when: env != "staging" + when: env != "staging" and datacenter != "iad2" # Set-up Pagure @@ -137,7 +137,7 @@ - name: create the database scheme command: /usr/bin/python2 /usr/share/pagure/pagure_createdb.py - when: env != "staging" + when: env != "staging" and datacenter != "iad2" changed_when: "1 != 1" environment: PAGURE_CONFIG: /etc/pagure/pagure.cfg @@ -147,7 +147,7 @@ - name: create the database scheme command: /usr/bin/python3 /usr/share/pagure/pagure_createdb.py - when: env == "staging" + when: env == "staging" or datacenter == "iad2" changed_when: "1 != 1" environment: PAGURE_CONFIG: /etc/pagure/pagure.cfg @@ -325,7 +325,7 @@ job: /usr/bin/python2 /usr/libexec/pagure-dist-git/pagure_poc.py /srv/cache/extras cron_file: pagure-poc state: present - when: env != "staging" + when: env != "staging" and datacenter != "iad2" tags: - pagure @@ -337,7 +337,7 @@ job: /usr/bin/python2 /usr/libexec/pagure-dist-git/pagure_bz.py /srv/cache/extras cron_file: pagure-bz state: present - when: env != "staging" + when: env != "staging" and datacenter != "iad2" tags: - pagure @@ -349,7 +349,7 @@ job: /usr/bin/python2 /usr/libexec/pagure-dist-git/pagure_owner_alias.py /srv/cache/extras cron_file: pagure-owner-alias state: present - when: env != "staging" + when: env != "staging" and datacenter != "iad2" tags: - pagure @@ -362,7 +362,7 @@ job: /usr/bin/python3 /usr/libexec/pagure-dist-git/pagure_poc.py /srv/cache/extras cron_file: pagure-poc state: present - when: env == "staging" + when: env == "staging" or datacenter == "iad2" tags: - pagure @@ -374,7 +374,7 @@ job: /usr/bin/python3 /usr/libexec/pagure-dist-git/pagure_bz.py /srv/cache/extras cron_file: pagure-bz state: present - when: env == "staging" + when: env == "staging" or datacenter == "iad2" tags: - pagure @@ -386,7 +386,7 @@ job: /usr/bin/python3 /usr/libexec/pagure-dist-git/pagure_owner_alias.py /srv/cache/extras cron_file: pagure-owner-alias state: present - when: env == "staging" + when: env == "staging" or datacenter == "iad2" tags: - pagure @@ -396,7 +396,7 @@ package: name={{ item }} state=present with_items: - python2-fedora-messaging - when: env != "staging" + when: env != "staging" and datacenter != "iad2" tags: - pagure - fedora-messaging @@ -405,7 +405,7 @@ package: name={{ item }} state=present with_items: - fedora-messaging - when: env == "staging" + when: env == "staging" or datacenter == "iad2" tags: - pagure - fedora-messaging diff --git a/roles/distgit/tasks/main.yml b/roles/distgit/tasks/main.yml index 3ddc726d87..0979670e02 100644 --- a/roles/distgit/tasks/main.yml +++ b/roles/distgit/tasks/main.yml @@ -15,7 +15,7 @@ - python-fedmsg-genacls - /usr/sbin/semanage - mod_auth_openidc - when: env != "staging" + when: env != "staging" and datacenter != "iad2" tags: - distgit @@ -28,7 +28,7 @@ stream=2.3 profiles= state=enabled - when: env == "staging" + when: env == "staging" or datacenter == "iad2" - name: install the needed packages package: name={{item}} state=present @@ -39,7 +39,7 @@ - mod_auth_gssapi - /usr/sbin/semanage - mod_auth_openidc - when: env == "staging" + when: env == "staging" or datacenter == "iad2" tags: - distgit @@ -226,7 +226,7 @@ # This is the permission management for package maintainers, using Gitolite. - name: create the /var/log/gitolite directory file: path=/var/log/gitolite owner=root group=packager state=directory mode=2775 - when: env != "staging" + when: env != "staging" and datacenter != "iad2" tags: - distgit @@ -243,42 +243,42 @@ group=gen-acls shell=/bin/bash home=/srv/git - when: env != "staging" + when: env != "staging" and datacenter != "iad2" tags: - distgit - name: create the /etc/gitolite/conf directory file: path=/etc/gitolite/conf owner=pagure group=pagure state=directory mode=0755 - when: env != "staging" + when: env != "staging" and datacenter != "iad2" tags: - distgit - name: create the /etc/gitolite/logs directory file: path=/etc/gitolite/logs owner=pagure group=packager state=directory mode=0775 - when: env != "staging" + when: env != "staging" and datacenter != "iad2" tags: - distgit - name: create the /etc/gitolite/local/VREF directory file: path=/etc/gitolite/local/VREF owner=pagure group=packager state=directory mode=0775 - when: env != "staging" + when: env != "staging" and datacenter != "iad2" tags: - distgit - name: create /etc/gitolite/gitolite.rc template: src=gitolite.rc dest=/etc/gitolite/gitolite.rc owner=root group=root mode=0755 - when: env != "staging" + when: env != "staging" and datacenter != "iad2" tags: - distgit - name: Create the rpms symlink (should not be needed, might still be used by some old scripts) command: ln -s /srv/git/repositories/ /srv/git/rpms creates=/srv/git/rpms - when: env != "staging" + when: env != "staging" and datacenter != "iad2" tags: - config - distgit @@ -286,7 +286,7 @@ - name: Create the gitolite.rc symlink command: ln -s /etc/gitolite/gitolite.rc /srv/git/.gitolite.rc creates=/srv/git/.gitolite.rc - when: env != "staging" + when: env != "staging" and datacenter != "iad2" tags: - config - distgit @@ -294,7 +294,7 @@ - name: Create the gitolite configuration symlink command: ln -s /etc/gitolite/ /srv/git/.gitolite creates=/srv/git/.gitolite - when: env != "staging" + when: env != "staging" and datacenter != "iad2" tags: - config - distgit @@ -302,12 +302,12 @@ - name: Copy in RepoAliases.header copy: src=RepoAliases.header dest=/etc/gitolite/RepoAliases.header owner=root group=root mode=0755 - when: env != "staging" + when: env != "staging" and datacenter != "iad2" - name: Create the update-block-push-origin symlink command: ln -s /usr/share/git-core/update-block-push-origin /etc/gitolite/local/VREF/update-block-push-origin creates=/etc/gitolite/local/VREF/update-block-push-origin - when: env != "staging" + when: env != "staging" and datacenter != "iad2" tags: - config - distgit @@ -315,7 +315,7 @@ - name: install the fedmsg configuration template: src=fedmsg-genacls-config.py dest=/etc/fedmsg.d/genacls.py owner=root group=root mode=0644 - when: env != "staging" + when: env != "staging" and datacenter != "iad2" tags: - distgit @@ -324,7 +324,7 @@ with_items: - /usr/local/bin/genacls.sh - /etc/cron.d/genacls.cron - when: env != "staging" + when: env != "staging" and datacenter != "iad2" tags: - config - distgit @@ -343,7 +343,7 @@ - name: Save the list the users having a shell access template: src=gitolite_admins dest=/etc/gitolite/admins owner=gen-acls group=packager mode=660 - when: env != "staging" + when: env != "staging" and datacenter != "iad2" tags: - config - distgit @@ -353,11 +353,11 @@ with_items: - {name: /etc/gitolite/hooks, mode: 770, state: directory} - {name: /etc/gitolite/hooks/common, mode: 770, state: directory} - when: env != "staging" + when: env != "staging" and datacenter != "iad2" - name: Fix permissions on the Gitolite stuff (touch update if it does not exist) copy: content="" dest=/etc/gitolite/hooks/common/update force=no owner=root group=packager mode=0755 - when: env != "staging" + when: env != "staging" and datacenter != "iad2" tags: - distgit - config @@ -482,7 +482,7 @@ - name: setup grokmirror for repos package: name=python-grokmirror state=installed - when: env != "staging" + when: env != "staging" and datacenter != "iad2" tags: - grokmirror - pkgs @@ -505,7 +505,7 @@ - name: run initial grokmirror run command: /usr/bin/grok-manifest -m /srv/git/grokmirror/manifest.js.gz -t /srv/git/repositories/ creates=/srv/git/grokmirror/manifest.js.gz - when: env != "staging" + when: env != "staging" and datacenter != "iad2" tags: - grokmirror - pkgs diff --git a/roles/git/hooks/tasks/main.yml b/roles/git/hooks/tasks/main.yml index 3ea0eba440..87257b64d3 100644 --- a/roles/git/hooks/tasks/main.yml +++ b/roles/git/hooks/tasks/main.yml @@ -10,7 +10,7 @@ - python-kitchen - python-pygit2 - fedora-messaging - when: env != "staging" + when: env != "staging" and datacenter != "iad2" tags: - git - git/hooks @@ -25,7 +25,7 @@ - python3-kitchen - python3-pygit2 - fedora-messaging - when: env == "staging" + when: env == "staging" or datacenter == "iad2" tags: - git - git/hooks