summaryrefslogtreecommitdiffstats
path: root/patches/fuel-main/0004-FIXME-cobbler-setup.sh-Keep-extra-RPM-repos.patch
diff options
context:
space:
mode:
Diffstat (limited to 'patches/fuel-main/0004-FIXME-cobbler-setup.sh-Keep-extra-RPM-repos.patch')
-rw-r--r--patches/fuel-main/0004-FIXME-cobbler-setup.sh-Keep-extra-RPM-repos.patch50
1 files changed, 19 insertions, 31 deletions
diff --git a/patches/fuel-main/0004-FIXME-cobbler-setup.sh-Keep-extra-RPM-repos.patch b/patches/fuel-main/0004-FIXME-cobbler-setup.sh-Keep-extra-RPM-repos.patch
index c16d05e5..e3dceeda 100644
--- a/patches/fuel-main/0004-FIXME-cobbler-setup.sh-Keep-extra-RPM-repos.patch
+++ b/patches/fuel-main/0004-FIXME-cobbler-setup.sh-Keep-extra-RPM-repos.patch
@@ -15,48 +15,36 @@ which is not currently possible, as we remove the extra RPM repository
entry from yum config at the end of container build.
Hacky temporary workaround:
-Keep extra RPM yum config after container is set up, only for cobbler.
+Re-add extra RPM yum config after container is set up, only for cobbler.
TODO: This patch should be dropped once cobbler-grub-aarch64 RPM
package gets upstreamed.
---
- docker/cobbler/setup.sh | 26 +++++++++++++++-----------
- 1 file changed, 15 insertions(+), 11 deletions(-)
+ docker/cobbler/setup.sh | 14 ++++++++++++++
+ 1 file changed, 14 insertions(+)
diff --git a/docker/cobbler/setup.sh b/docker/cobbler/setup.sh
-index 90627a8..1a0b0d2 100644
+index 90627a8..508eaa4 100644
--- a/docker/cobbler/setup.sh
+++ b/docker/cobbler/setup.sh
-@@ -68,17 +68,21 @@ puppet apply --debug --verbose --color false --detailed-exitcodes \
- /etc/puppet/modules/nailgun/examples/cobbler-only.pp || [[ $? == 2 ]]
+@@ -80,6 +80,20 @@ baseurl=file:/var/www/nailgun/mos-centos/x86_64
+ gpgcheck=0
+ EOF
-
--cat << EOF > /etc/yum.repos.d/nailgun.repo
--[nailgun]
--name=Nailgun Local Repo
--baseurl=file:/var/www/nailgun/centos/x86_64
--gpgcheck=0
--
--[mos]
--name=MOS Local Repo
--baseurl=file:/var/www/nailgun/mos-centos/x86_64
--gpgcheck=0
--EOF
-+## FIXME(armband): Keep extra RPM repository in Cobbler container
-+# Normally, extra RPM repos are discarded post-build, but we
++## FIXME(armband): Add extra RPM repository in Cobbler container
++# Normally, extra RPM repos are not re-added post-build, but we
+# need cobbler-grub-aarch64 during each container start.
+
-+# cat << EOF > /etc/yum.repos.d/nailgun.repo
-+# [nailgun]
-+# name=Nailgun Local Repo
-+# baseurl=file:/var/www/nailgun/centos/x86_64
-+# gpgcheck=0
++for repo in ${EXTRA_RPM_REPOS}; do
++ IFS=, read -a repo_args <<< "$repo"
++ cat << EOF >> /etc/yum.repos.d/nailgun.repo
+
-+# [mos]
-+# name=MOS Local Repo
-+# baseurl=file:/var/www/nailgun/mos-centos/x86_64
-+# gpgcheck=0
-+# EOF
-
++[extra-repo-${repo_args[0]}]
++name=MOS Extra Repo ${repo_args[0]}
++baseurl=file:/var/www/nailgun/extra-repos/${repo_args[0]}
++gpgcheck=0
++EOF
++done
yum clean all
+