diff --git a/Containerfile b/Containerfile deleted file mode 100644 index a800110..0000000 --- a/Containerfile +++ /dev/null @@ -1,34 +0,0 @@ -FROM registry.fedoraproject.org/fedora:latest - -# Variables for URLs and versions -ARG CENTOS_VERSION=10 -ARG EPEL_VERSION=10 -ARG RSYNC_MIRROR=rsync://mirror.in2p3.fr -ARG CENTOS_PATH=/pub/linux/centos-stream/${CENTOS_VERSION}-stream/ -ARG EPEL_PATH=/pub/epel/${EPEL_VERSION}/ - -# Install required tools -RUN dnf install -y rsync nginx && \ - dnf clean all - -# Copy exclusions file -COPY rsync-excludes.txt /etc/rsync-excludes.txt - -# Build rsync options and sync repositories -RUN </dev/null; then PODMAN_ARGS+=( --from "localhost/mirrors/centos-stream-${CENTOS_VERSION}:latest" ) + PODMAN_ARGS+=( --file Containerfile.sync ) +else + PODMAN_ARGS+=( --file Containerfile.base ) fi # Build the image. # Note: during the build, the repositories will be synced and the result will be stored in the image. +echo podman build "${PODMAN_ARGS[@]}" . podman build "${PODMAN_ARGS[@]}" . podman tag "localhost/mirrors/centos-stream-${CENTOS_VERSION}:${TS}" "localhost/mirrors/centos-stream-${CENTOS_VERSION}:latest"