mirror of
https://github.com/edgelesssys/constellation.git
synced 2024-12-18 12:24:32 -05:00
58e7af5364
rpm doesn't work properly when run on the host.
18 lines
732 B
Bash
Executable File
18 lines
732 B
Bash
Executable File
#!/usr/bin/env bash
|
|
set -euxo pipefail
|
|
|
|
# create mountpoints in /etc
|
|
mkdir -p "${BUILDROOT}"/etc/{cni,kubernetes}
|
|
|
|
# move issue files away from /etc
|
|
# to allow /run/issue and /run/issue.d to take precedence
|
|
mv "${BUILDROOT}/etc/issue.d" "${BUILDROOT}/usr/lib/issue.d" || true
|
|
|
|
# generate reproducible package manifest
|
|
mkdir -p "${BUILDROOT}/usr/share/constellation"
|
|
mkosi-chroot rpm -qa --qf '%{name};%{version};%{license}\n' --dbpath "/var/lib/rpm/" | LC_ALL=C sort | tee "${BUILDROOT}/usr/share/constellation/packagemanifest"
|
|
cp "${BUILDROOT}/usr/share/constellation/packagemanifest" "${OUTPUTDIR}/"
|
|
|
|
# copy rpmdb to outputs
|
|
cp "${BUILDROOT}"/var/lib/rpm/{rpmdb.sqlite-wal,rpmdb.sqlite-shm,rpmdb.sqlite,.rpm.lock} "${OUTPUTDIR}/"
|