I suppose if you want to be able to copy the rules directly without having to install as an RPM, the

I suppose if you want to be able to copy the rules directly without having to install as an RPM, then we could make further changes:
RUN mkdir /tmp/ublue-os/udev-rules
RUN rpm2cpio /tmp/ublue-os/rpmbuild/RPMS/noarch/ublue-os-udev-rules-*.noarch.rpm | cpio -idmv --directory /tmp/ublue-os/udev-rules
FROM scratch

COPY --from=builder /tmp/ublue-os/udev-rules/* /
COPY --from=builder /tmp/ublue-os/rpmbuild/RPMS/noarch/ublue-os-udev-rules-*.noarch.rpm  /ublue-os-udev-rules.noarch.rpm
Was this page helpful?