Skip to content

Commit

Permalink
Use ex rebuild to pull from COPR
Browse files Browse the repository at this point in the history
This works around coreos/rpm-ostree#4037
  • Loading branch information
cgwalters committed Sep 23, 2022
1 parent ef639ab commit 2eb99d7
Showing 1 changed file with 4 additions and 9 deletions.
13 changes: 4 additions & 9 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ ARG FEDORA_COREOS_VERSION=412.37.0
WORKDIR /go/src/github.com/openshift/okd-machine-os
COPY . .
COPY --from=artifacts /srv/repo/*.rpm /tmp/rpms/
ADD overrides.yaml /etc/rpm-ostree/origin.d/overrides.yaml
RUN cat /etc/os-release \
&& rpm-ostree --version \
&& ostree --version \
Expand All @@ -23,18 +24,12 @@ RUN cat /etc/os-release \
/tmp/rpms/openshift-clients-[0-9]*.rpm \
/tmp/rpms/openshift-hyperkube-*.rpm \
&& rpm-ostree cliwrap install-to-root / \
&& rpm-ostree override replace \
--experimental --freeze \
--from repo=coreos-continuous \
rpm-ostree rpm-ostree-libs \
https://kojipkgs.fedoraproject.org//packages/kernel/5.18.0/60.fc37/x86_64/kernel-5.18.0-60.fc37.x86_64.rpm \
https://kojipkgs.fedoraproject.org//packages/kernel/5.18.0/60.fc37/x86_64/kernel-core-5.18.0-60.fc37.x86_64.rpm \
https://kojipkgs.fedoraproject.org//packages/kernel/5.18.0/60.fc37/x86_64/kernel-modules-5.18.0-60.fc37.x86_64.rpm \
&& rpm-ostree override replace https://koji.fedoraproject.org/koji/buildinfo?buildID=1969515 \
&& rpm-ostree ex rebuild \
&& rpm-ostree cleanup -m \
&& sed -i 's/^enabled=1/enabled=0/g' /etc/yum.repos.d/*.repo \
&& ln -s /usr/sbin/ovs-vswitchd.dpdk /usr/sbin/ovs-vswitchd \
&& rm -rf /go /tmp/rpms /var/cache \
&& ostree container commit
&& rm -rf /go /tmp/rpms /var/cache
LABEL io.openshift.release.operator=true \
io.openshift.build.version-display-names="machine-os=Fedora CoreOS" \
io.openshift.build.versions="machine-os=${FEDORA_COREOS_VERSION}"
Expand Down

0 comments on commit 2eb99d7

Please sign in to comment.