diff --git a/containers-common.spec b/containers-common.spec index f305f55..4e80518 100644 --- a/containers-common.spec +++ b/containers-common.spec @@ -15,7 +15,7 @@ Epoch: 4 Name: containers-common Version: 1 -Release: 9%{?dist} +Release: 10%{?dist} Summary: Common configuration and documentation for containers License: ASL 2.0 BuildArch: noarch @@ -61,7 +61,7 @@ install -dp %{buildroot}%{_sharedstatedir}/containers/sigstore install -m0644 %{_sourcedir}/default.yaml %{buildroot}%{_sysconfdir}/containers/registries.d/default.yaml install -m0644 %{_sourcedir}/storage.conf %{buildroot}%{_sysconfdir}/containers/storage.conf install -m0644 %{_sourcedir}/registries.conf %{buildroot}%{_sysconfdir}/containers/registries.conf -install -m0644 %{_sourcedir}/shortnames.conf %{buildroot}%{_sysconfdir}/containers/registries.conf.d/shortnames.conf +install -m0644 %{_sourcedir}/shortnames.conf %{buildroot}%{_sysconfdir}/containers/registries.conf.d/000-shortnames.conf install -m0644 %{_sourcedir}/default-policy.json %{buildroot}%{_sysconfdir}/containers/policy.json # install manpages @@ -100,7 +100,7 @@ ln -s %{_sysconfdir}/yum.repos.d/redhat.repo %{buildroot}%{_datadir}/rhel/secret %dir %{_sysconfdir}/containers/registries.d %config(noreplace) %{_sysconfdir}/containers/policy.json %config(noreplace) %{_sysconfdir}/containers/registries.conf -%config(noreplace) %{_sysconfdir}/containers/registries.conf.d/shortnames.conf +%config(noreplace) %{_sysconfdir}/containers/registries.conf.d/000-shortnames.conf %config(noreplace) %{_sysconfdir}/containers/registries.d/default.yaml %config(noreplace) %{_sysconfdir}/containers/storage.conf %ghost %{_sysconfdir}/containers/containers.conf @@ -114,6 +114,9 @@ ln -s %{_sysconfdir}/yum.repos.d/redhat.repo %{buildroot}%{_datadir}/rhel/secret %{_datadir}/rhel/secrets/* %changelog +* Thu Feb 18 2021 Lokesh Mandvekar - 4:1-10 +- install shortnames.conf as 000-shrotnames.conf + * Mon Feb 15 2021 Dan Walsh - 4:1-9 - Remove registry.centos.org and add quay.io from registries.conf diff --git a/update.sh b/update.sh index 2c9f5cf..ba57c97 100755 --- a/update.sh +++ b/update.sh @@ -16,5 +16,7 @@ echo "Changing registries.conf..." sed -i 's/^#.*unqualified-search-registries.*=.*/unqualified-search-registries = ["registry.fedoraproject.org", "registry.access.redhat.com", "docker.io", "quay.io"]/g' \ registries.conf -echo '' >> registries.conf -echo 'short-name-mode="enforcing"' >> registries.conf +grep '\nshort-name-mode="enforcing"' registries.conf +if [[ $? == 1 ]]; then + echo -e '\nshort-name-mode="enforcing"' >> registries.conf +fi