From 419fac6c17e13915ea75744c2095911fa74f3eee Mon Sep 17 00:00:00 2001 From: Sinny Kumari Date: Wed, 6 Feb 2019 15:17:31 +0530 Subject: [PATCH] Necessary changes to accommodate ostree repo move from atomic/ to ostree/ Use metalink url for AH ISO creation Signed-off-by: Sinny Kumari --- roles/bodhi2/backend/files/new-updates-sync | 26 +++--- .../backend/templates/pungi.rpm.conf.j2 | 9 +- .../httpd/dl.fedoraproject.org/rewrite.conf | 4 - .../ostree/files/cron-sync-ostree-summary | 2 +- .../files/robosignatory.production.py | 82 +++++++++---------- 5 files changed, 60 insertions(+), 63 deletions(-) diff --git a/roles/bodhi2/backend/files/new-updates-sync b/roles/bodhi2/backend/files/new-updates-sync index 743bc795b7..14c97d5835 100755 --- a/roles/bodhi2/backend/files/new-updates-sync +++ b/roles/bodhi2/backend/files/new-updates-sync @@ -18,18 +18,18 @@ FEDORADEST = '/pub/fedora/linux/updates/' FEDORAMODDEST = '/pub/fedora/linux/modular/updates/' FEDORAALTDEST = '/pub/fedora-secondary/updates/' EPELDEST = '/pub/epel/' -ATOMICSOURCE = '/mnt/koji/compose/atomic/repo/' -ATOMICDEST = '/mnt/koji/atomic/repo/' +OSTREESOURCE = '/mnt/koji/compose/ostree/repo/' +OSTREEDEST = '/mnt/koji/ostree/repo/' RELEASES = {'f29': {'topic': 'fedora', 'version': '29', 'modules': ['fedora', 'fedora-secondary'], 'repos': {'updates': { 'from': 'f29-updates', 'ostrees': [{'ref': 'fedora/29/%(arch)s/updates/atomic-host', - 'dest': ATOMICDEST, + 'dest': OSTREEDEST, 'arches': ['x86_64', 'ppc64le', 'aarch64']}, {'ref': 'fedora/29/x86_64/updates/silverblue', - 'dest': ATOMICDEST}], + 'dest': OSTREEDEST}], 'to': [{'arches': ['x86_64', 'armhfp', 'aarch64', 'source'], 'dest': os.path.join(FEDORADEST, '29', 'Everything')}, {'arches': ['i386', 'ppc64le', 's390x'], @@ -38,10 +38,10 @@ RELEASES = {'f29': {'topic': 'fedora', 'updates-testing': { 'from': 'f29-updates-testing', 'ostrees': [{'ref': 'fedora/29/%(arch)s/testing/atomic-host', - 'dest': ATOMICDEST, + 'dest': OSTREEDEST, 'arches': ['x86_64', 'ppc64le', 'aarch64']}, {'ref': 'fedora/29/x86_64/testing/silverblue', - 'dest': ATOMICDEST}], + 'dest': OSTREEDEST}], 'to': [{'arches': ['x86_64', 'aarch64', 'armhfp', 'source'], 'dest': os.path.join(FEDORADEST, 'testing', '29', 'Everything')}, {'arches': ['i386', 'ppc64le', 's390x'], @@ -74,13 +74,13 @@ RELEASES = {'f29': {'topic': 'fedora', 'repos': {'updates': { 'from': 'f28-updates', 'ostrees': [{'ref': 'fedora/28/%(arch)s/updates/atomic-host', - 'dest': ATOMICDEST, + 'dest': OSTREEDEST, 'arches': ['x86_64', 'ppc64le', 'aarch64']}, {'ref': 'fedora/28/x86_64/updates/workstation', - 'dest': ATOMICDEST}, + 'dest': OSTREEDEST}, # Hack around for the fact that ostree on f25 doesn't know links {'ref': 'fedora/28/x86_64/workstation', - 'dest': ATOMICDEST}], + 'dest': OSTREEDEST}], 'to': [{'arches': ['x86_64', 'armhfp', 'aarch64', 'source'], 'dest': os.path.join(FEDORADEST, '28', 'Everything')}, {'arches': ['i386', 'ppc64', 'ppc64le', 's390x'], @@ -89,10 +89,10 @@ RELEASES = {'f29': {'topic': 'fedora', 'updates-testing': { 'from': 'f28-updates-testing', 'ostrees': [{'ref': 'fedora/28/%(arch)s/testing/atomic-host', - 'dest': ATOMICDEST, + 'dest': OSTREEDEST, 'arches': ['x86_64', 'ppc64le', 'aarch64']}, {'ref': 'fedora/28/x86_64/testing/workstation', - 'dest': ATOMICDEST}], + 'dest': OSTREEDEST}], 'to': [{'arches': ['x86_64', 'aarch64', 'armhfp', 'source'], 'dest': os.path.join(FEDORADEST, 'testing', '28', 'Everything')}, {'arches': ['i386', 'ppc64', 'ppc64le', 's390x'], @@ -170,7 +170,7 @@ def get_ostree_ref(repo, ref): def sync_ostree(dst, ref): - src_commit = get_ostree_ref(ATOMICSOURCE, ref) + src_commit = get_ostree_ref(OSTREESOURCE, ref) dst_commit = get_ostree_ref(dst, ref) if src_commit == dst_commit: logger.info('OSTree at %s, ref %s in sync', dst, ref) @@ -180,7 +180,7 @@ def sync_ostree(dst, ref): logger.info('Syncing OSTree to %s, ref %s: %s -> %s', dst, ref, src_commit, dst_commit) cmd = ['ostree', 'pull-local', '--verbose', '--repo', - dst, ATOMICSOURCE, ref] + dst, OSTREESOURCE, ref] out = run_command(cmd) cmd = ['ostree', 'summary', '--verbose', '--repo', dst, '--update'] run_command(cmd) diff --git a/roles/bodhi2/backend/templates/pungi.rpm.conf.j2 b/roles/bodhi2/backend/templates/pungi.rpm.conf.j2 index 91bb866e7c..7777be1e79 100644 --- a/roles/bodhi2/backend/templates/pungi.rpm.conf.j2 +++ b/roles/bodhi2/backend/templates/pungi.rpm.conf.j2 @@ -141,7 +141,7 @@ ostree = { "https://kojipkgs{{ env_suffix }}.fedoraproject.org/compose/[[ release.version_int ]]/latest-Fedora-[[ release.version_int ]]/compose/Everything/$basearch/os/" [% endif %] ] - "ostree_repo": "/mnt/koji/compose/atomic/repo", + "ostree_repo": "/mnt/koji/compose/ostree/repo", [% if request.name == 'stable' %] "ostree_ref": "fedora/[[ release.version_int ]]/${basearch}/updates/atomic-host", [% else %] @@ -174,7 +174,7 @@ ostree = { "https://kojipkgs{{ env_suffix }}.fedoraproject.org/compose/[[ release.version_int ]]/latest-Fedora-[[ release.version_int ]]/compose/Everything/$basearch/os/" [% endif %] ] - "ostree_repo": "/mnt/koji/compose/atomic/repo", + "ostree_repo": "/mnt/koji/compose/ostree/repo", # For f29+ we are changing the ref to silverblue. For f28/f27 let the files # still specify the workstation ref. [% if release.version_int >= 29 %] @@ -301,10 +301,11 @@ ostree_installer = [ 'add_template': ['ostree-based-installer/lorax-configure-repo.tmpl', 'ostree-based-installer/lorax-embed-repo.tmpl'], 'add_template_var': [ - 'ostree_install_repo=https://kojipkgs.fedoraproject.org/compose/atomic/repo/', - 'ostree_update_repo=https://dl.fedoraproject.org/atomic/repo/', + 'ostree_install_repo=https://kojipkgs.fedoraproject.org/compose/ostree/repo/', + 'ostree_update_repo=https://ostree.fedoraproject.org', 'ostree_osname=fedora-atomic', 'ostree_oskey=fedora-[[ release.version_int ]]-primary', + 'ostree_contenturl=mirrorlist=https://ostree.fedoraproject.org/mirrorlist', 'ostree_install_ref=fedora/[[ release.version_int ]]/[[ arch ]]/[% if request.name == "testing" %]testing[% else %]updates[% endif %]/atomic-host', 'ostree_update_ref=fedora/[[ release.version_int ]]/[[ arch ]]/atomic-host', ], diff --git a/roles/download/files/httpd/dl.fedoraproject.org/rewrite.conf b/roles/download/files/httpd/dl.fedoraproject.org/rewrite.conf index db5285cbf4..581012ed97 100644 --- a/roles/download/files/httpd/dl.fedoraproject.org/rewrite.conf +++ b/roles/download/files/httpd/dl.fedoraproject.org/rewrite.conf @@ -15,9 +15,5 @@ RedirectMatch 302 ^/atomic/repo/deltas/(.*) https://d2uk5hbyrobdzx.cloudfront.ne RedirectMatch 302 ^/atomic/repo/objects/(.*) https://d2uk5hbyrobdzx.cloudfront.net/objects/$1 RedirectMatch 302 ^/atomic/repo/(.*) https://kojipkgs.fedoraproject.org/ostree/repo/$1 -RedirectMatch 302 ^/cdn-testing/atomic/repo/deltas/(.*) https://d1dgksnh07m2j5.cloudfront.net/deltas/$1 -RedirectMatch 302 ^/cdn-testing/atomic/repo/objects/(.*) https://d1dgksnh07m2j5.cloudfront.net/objects/$1 -RedirectMatch 302 ^/cdn-testing/atomic/repo/(.*) https://kojipkgs.fedoraproject.org/atomic/repo/$1 - RedirectMatch 302 ^/iot/repo/objects/(.*) https://d35xkejx7yn5rc.cloudfront.net/$1 RedirectMatch 302 ^/iot/repo/(.*) https://kojipkgs.fedoraproject.org/compose/iot/repo/$1 diff --git a/roles/fedora-web/ostree/files/cron-sync-ostree-summary b/roles/fedora-web/ostree/files/cron-sync-ostree-summary index 80ef592b61..a3b96fa70d 100644 --- a/roles/fedora-web/ostree/files/cron-sync-ostree-summary +++ b/roles/fedora-web/ostree/files/cron-sync-ostree-summary @@ -1,4 +1,4 @@ MAILTO="" -*/15 * * * * root /usr/bin/curl -f https://kojipkgs.fedoraproject.org/atomic/repo/summary -o /srv/web/ostree/summary.new && mv /srv/web/ostree/summary.new /srv/web/ostree/summary +*/15 * * * * root /usr/bin/curl -f https://kojipkgs.fedoraproject.org/ostree/repo/summary -o /srv/web/ostree/summary.new && mv /srv/web/ostree/summary.new /srv/web/ostree/summary MAILTO="" */15 * * * * root /usr/bin/curl -f https://kojipkgs.fedoraproject.org/compose/iot/repo/summary -o /srv/web/ostree/iot/summary.new && mv /srv/web/ostree/iot/summary.new /srv/web/ostree/iot/summary diff --git a/roles/robosignatory/files/robosignatory.production.py b/roles/robosignatory/files/robosignatory.production.py index f68366dac4..9dd5543e39 100644 --- a/roles/robosignatory/files/robosignatory.production.py +++ b/roles/robosignatory/files/robosignatory.production.py @@ -306,167 +306,167 @@ config = { 'key': 'fedora-28' }, 'fedora/26/x86_64/testing/atomic-host': { - 'directory': '/mnt/fedora_koji/koji/compose/atomic/repo/', + 'directory': '/mnt/fedora_koji/koji/compose/ostree/repo/', 'key': 'fedora-26' }, 'fedora/26/x86_64/updates/atomic-host': { - 'directory': '/mnt/fedora_koji/koji/compose/atomic/repo/', + 'directory': '/mnt/fedora_koji/koji/compose/ostree/repo/', 'key': 'fedora-26' }, 'fedora/26/x86_64/atomic-host': { - 'directory': '/mnt/fedora_koji/koji/compose/atomic/repo/', + 'directory': '/mnt/fedora_koji/koji/compose/ostree/repo/', 'key': 'fedora-26' }, 'fedora/26/x86_64/workstation': { - 'directory': '/mnt/fedora_koji/koji/compose/atomic/repo/', + 'directory': '/mnt/fedora_koji/koji/compose/ostree/repo/', 'key': 'fedora-26' }, 'fedora/27/x86_64/updates/workstation': { - 'directory': '/mnt/fedora_koji/koji/compose/atomic/repo/', + 'directory': '/mnt/fedora_koji/koji/compose/ostree/repo/', 'key': 'fedora-27' }, 'fedora/27/x86_64/testing/workstation': { - 'directory': '/mnt/fedora_koji/koji/compose/atomic/repo/', + 'directory': '/mnt/fedora_koji/koji/compose/ostree/repo/', 'key': 'fedora-27' }, 'fedora/27/x86_64/updates/atomic-host': { - 'directory': '/mnt/fedora_koji/koji/compose/atomic/repo/', + 'directory': '/mnt/fedora_koji/koji/compose/ostree/repo/', 'key': 'fedora-27' }, 'fedora/27/ppc64le/updates/atomic-host': { - 'directory': '/mnt/fedora_koji/koji/compose/atomic/repo/', + 'directory': '/mnt/fedora_koji/koji/compose/ostree/repo/', 'key': 'fedora-27' }, 'fedora/27/aarch64/updates/atomic-host': { - 'directory': '/mnt/fedora_koji/koji/compose/atomic/repo/', + 'directory': '/mnt/fedora_koji/koji/compose/ostree/repo/', 'key': 'fedora-27' }, 'fedora/27/x86_64/testing/atomic-host': { - 'directory': '/mnt/fedora_koji/koji/compose/atomic/repo/', + 'directory': '/mnt/fedora_koji/koji/compose/ostree/repo/', 'key': 'fedora-27' }, 'fedora/27/ppc64le/testing/atomic-host': { - 'directory': '/mnt/fedora_koji/koji/compose/atomic/repo/', + 'directory': '/mnt/fedora_koji/koji/compose/ostree/repo/', 'key': 'fedora-27' }, 'fedora/27/aarch64/testing/atomic-host': { - 'directory': '/mnt/fedora_koji/koji/compose/atomic/repo/', + 'directory': '/mnt/fedora_koji/koji/compose/ostree/repo/', 'key': 'fedora-27' }, 'fedora/27/x86_64/workstation': { - 'directory': '/mnt/fedora_koji/koji/compose/atomic/repo/', + 'directory': '/mnt/fedora_koji/koji/compose/ostree/repo/', 'key': 'fedora-27' }, 'fedora/28/x86_64/atomic-host': { - 'directory': '/mnt/fedora_koji/koji/compose/atomic/repo/', + 'directory': '/mnt/fedora_koji/koji/compose/ostree/repo/', 'key': 'fedora-28' }, 'fedora/28/ppc64le/atomic-host': { - 'directory': '/mnt/fedora_koji/koji/compose/atomic/repo/', + 'directory': '/mnt/fedora_koji/koji/compose/ostree/repo/', 'key': 'fedora-28' }, 'fedora/28/aarch64/atomic-host': { - 'directory': '/mnt/fedora_koji/koji/compose/atomic/repo/', + 'directory': '/mnt/fedora_koji/koji/compose/ostree/repo/', 'key': 'fedora-28' }, 'fedora/28/x86_64/updates/atomic-host': { - 'directory': '/mnt/fedora_koji/koji/compose/atomic/repo/', + 'directory': '/mnt/fedora_koji/koji/compose/ostree/repo/', 'key': 'fedora-28' }, 'fedora/28/ppc64le/updates/atomic-host': { - 'directory': '/mnt/fedora_koji/koji/compose/atomic/repo/', + 'directory': '/mnt/fedora_koji/koji/compose/ostree/repo/', 'key': 'fedora-28' }, 'fedora/28/aarch64/updates/atomic-host': { - 'directory': '/mnt/fedora_koji/koji/compose/atomic/repo/', + 'directory': '/mnt/fedora_koji/koji/compose/ostree/repo/', 'key': 'fedora-28' }, 'fedora/28/x86_64/testing/atomic-host': { - 'directory': '/mnt/fedora_koji/koji/compose/atomic/repo/', + 'directory': '/mnt/fedora_koji/koji/compose/ostree/repo/', 'key': 'fedora-28' }, 'fedora/28/ppc64le/testing/atomic-host': { - 'directory': '/mnt/fedora_koji/koji/compose/atomic/repo/', + 'directory': '/mnt/fedora_koji/koji/compose/ostree/repo/', 'key': 'fedora-28' }, 'fedora/28/aarch64/testing/atomic-host': { - 'directory': '/mnt/fedora_koji/koji/compose/atomic/repo/', + 'directory': '/mnt/fedora_koji/koji/compose/ostree/repo/', 'key': 'fedora-28' }, 'fedora/28/x86_64/workstation': { - 'directory': '/mnt/fedora_koji/koji/compose/atomic/repo/', + 'directory': '/mnt/fedora_koji/koji/compose/ostree/repo/', 'key': 'fedora-28' }, 'fedora/28/x86_64/updates/workstation': { - 'directory': '/mnt/fedora_koji/koji/compose/atomic/repo/', + 'directory': '/mnt/fedora_koji/koji/compose/ostree/repo/', 'key': 'fedora-28' }, 'fedora/28/x86_64/testing/workstation': { - 'directory': '/mnt/fedora_koji/koji/compose/atomic/repo/', + 'directory': '/mnt/fedora_koji/koji/compose/ostree/repo/', 'key': 'fedora-28' }, 'fedora/29/x86_64/atomic-host': { - 'directory': '/mnt/fedora_koji/koji/compose/atomic/repo/', + 'directory': '/mnt/fedora_koji/koji/compose/ostree/repo/', 'key': 'fedora-29' }, 'fedora/29/ppc64le/atomic-host': { - 'directory': '/mnt/fedora_koji/koji/compose/atomic/repo/', + 'directory': '/mnt/fedora_koji/koji/compose/ostree/repo/', 'key': 'fedora-29' }, 'fedora/29/aarch64/atomic-host': { - 'directory': '/mnt/fedora_koji/koji/compose/atomic/repo/', + 'directory': '/mnt/fedora_koji/koji/compose/ostree/repo/', 'key': 'fedora-29' }, 'fedora/29/x86_64/updates/atomic-host': { - 'directory': '/mnt/fedora_koji/koji/compose/atomic/repo/', + 'directory': '/mnt/fedora_koji/koji/compose/ostree/repo/', 'key': 'fedora-29' }, 'fedora/29/ppc64le/updates/atomic-host': { - 'directory': '/mnt/fedora_koji/koji/compose/atomic/repo/', + 'directory': '/mnt/fedora_koji/koji/compose/ostree/repo/', 'key': 'fedora-29' }, 'fedora/29/aarch64/updates/atomic-host': { - 'directory': '/mnt/fedora_koji/koji/compose/atomic/repo/', + 'directory': '/mnt/fedora_koji/koji/compose/ostree/repo/', 'key': 'fedora-29' }, 'fedora/29/x86_64/testing/atomic-host': { - 'directory': '/mnt/fedora_koji/koji/compose/atomic/repo/', + 'directory': '/mnt/fedora_koji/koji/compose/ostree/repo/', 'key': 'fedora-29' }, 'fedora/29/ppc64le/testing/atomic-host': { - 'directory': '/mnt/fedora_koji/koji/compose/atomic/repo/', + 'directory': '/mnt/fedora_koji/koji/compose/ostree/repo/', 'key': 'fedora-29' }, 'fedora/29/aarch64/testing/atomic-host': { - 'directory': '/mnt/fedora_koji/koji/compose/atomic/repo/', + 'directory': '/mnt/fedora_koji/koji/compose/ostree/repo/', 'key': 'fedora-29' }, 'fedora/29/x86_64/silverblue': { - 'directory': '/mnt/fedora_koji/koji/compose/atomic/repo/', + 'directory': '/mnt/fedora_koji/koji/compose/ostree/repo/', 'key': 'fedora-29' }, 'fedora/29/x86_64/updates/silverblue': { - 'directory': '/mnt/fedora_koji/koji/compose/atomic/repo/', + 'directory': '/mnt/fedora_koji/koji/compose/ostree/repo/', 'key': 'fedora-29' }, 'fedora/29/x86_64/testing/silverblue': { - 'directory': '/mnt/fedora_koji/koji/compose/atomic/repo/', + 'directory': '/mnt/fedora_koji/koji/compose/ostree/repo/', 'key': 'fedora-29' }, 'fedora/rawhide/x86_64/atomic-host': { - 'directory': '/mnt/fedora_koji/koji/compose/atomic/repo/', + 'directory': '/mnt/fedora_koji/koji/compose/ostree/repo/', 'key': 'fedora-30' }, 'fedora/rawhide/ppc64le/atomic-host': { - 'directory': '/mnt/fedora_koji/koji/compose/atomic/repo/', + 'directory': '/mnt/fedora_koji/koji/compose/ostree/repo/', 'key': 'fedora-30' }, 'fedora/rawhide/aarch64/atomic-host': { - 'directory': '/mnt/fedora_koji/koji/compose/atomic/repo/', + 'directory': '/mnt/fedora_koji/koji/compose/ostree/repo/', 'key': 'fedora-30' }, 'fedora/rawhide/x86_64/silverblue': { - 'directory': '/mnt/fedora_koji/koji/compose/atomic/repo/', + 'directory': '/mnt/fedora_koji/koji/compose/ostree/repo/', 'key': 'fedora-30' }, }