1
0
mirror of https://github.com/quay/quay.git synced 2026-01-26 06:21:37 +03:00
Files
quay/hack/generate-rpms.sh
Marcus Kok e395957d72 build: rpm lock for konflux builds (PROJQUAY-8930) (#3888)
rpm lock for konflux builds
2025-05-22 10:23:35 -04:00

16 lines
651 B
Bash
Executable File

#!/bin/bash
DOCKER="docker"
CONTAINER_DIR="/work"
BASE_IMAGE="registry.access.redhat.com/ubi8/ubi-minimal:latest"
$DOCKER run -it $BASE_IMAGE cat /etc/yum.repos.d/ubi.repo > ubi.repo
sed -i '' 's/ubi-9-codeready-builder/codeready-builder-for-ubi-9-$basearch/' ubi.repo
sed -i '' 's/\[ubi-9/[ubi-9-for-$basearch/' ubi.repo
curl https://raw.githubusercontent.com/konflux-ci/rpm-lockfile-prototype/refs/heads/main/Containerfile \
| $DOCKER build -t localhost/rpm-lockfile-prototype -
$DOCKER run --rm -v ${PWD}:${CONTAINER_DIR} localhost/rpm-lockfile-prototype:latest --outfile=${CONTAINER_DIR}/rpms.lock.yaml --bare ${CONTAINER_DIR}/rpms.in.yaml