Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 11 additions & 2 deletions .github/workflows/build_container_images.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,14 +20,23 @@ jobs:
matrix:
image:
- "skopeo_cidev"
- "podman_cidev"
include:
- image: skopeo_cidev
context: container-images/skopeo_cidev
file: container-images/skopeo_cidev/Containerfile
- image: podman_cidev
context: .
file: container-images/podman_cidev/Containerfile
env:
IMAGE: ghcr.io/${{ github.repository_owner }}/${{ matrix.image }}:${{ inputs.tag }}
CONTEXT: container-images/${{ matrix.image }}
CONTEXT: ${{ matrix.context }}
CONTAINERFILE: ${{ matrix.file }}
steps:
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2

- name: Build image
run: podman build -t "$IMAGE" "$CONTEXT"
run: podman build -t "$IMAGE" -f "$CONTAINERFILE" "$CONTEXT"

- name: Log in to ghcr.io
if: ${{ inputs.push }}
Expand Down
13 changes: 13 additions & 0 deletions container-images/podman_cidev/Containerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
ARG BASE_NAME=fedora
ARG BASE_TAG=latest
ARG BUILD_NAME=fedora-current
FROM ${BASE_NAME}:${BASE_TAG}
ARG BUILD_NAME

# Required to keep perl & other tooling happy
ENV LC_ALL="C"

COPY images/fedora_packaging.sh /root/fedora_packaging.sh
RUN CONTAINER=1 bash /root/fedora_packaging.sh "${BUILD_NAME}" && \
dnf clean all && \
rm /root/fedora_packaging.sh
8 changes: 8 additions & 0 deletions container-images/podman_cidev/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# Podman CI/Dev image

Built and pushed to `ghcr.io/podman-container-tools/podman_cidev:<tag>` by
`.github/workflows/build_container_images.yml` on every release tag.

Used by the [podman](https://github.com/containers/podman) and
[buildah](https://github.com/containers/buildah) projects for container-based
CI. Not intended for use outside those contexts.
18 changes: 10 additions & 8 deletions images/fedora_packaging.sh
Original file line number Diff line number Diff line change
Expand Up @@ -209,11 +209,13 @@ dnf install -y "${INSTALL_PACKAGES[@]}"
# This may be due to activation of suggested/recommended dependency resolution.
dnf update -y

# Make /tmp tmpfs bigger, by default we only get 50%. Bump it to 75% so the tests have more storage.
# Do not use 100% so we do not run out of memory for the process itself if tests start leaking big
# files on /tmp.
mkdir -p /etc/systemd/system/tmp.mount.d
echo -e "[Mount]\nOptions=size=75%%,mode=1777\n" | $SUDO tee /etc/systemd/system/tmp.mount.d/override.conf

# "Enabling cgroup management from containers"
setsebool -P container_manage_cgroup true
if ! ((CONTAINER)); then
# Make /tmp tmpfs bigger, by default we only get 50%. Bump it to 75% so the tests have more storage.
# Do not use 100% so we do not run out of memory for the process itself if tests start leaking big
# files on /tmp.
mkdir -p /etc/systemd/system/tmp.mount.d
echo -e "[Mount]\nOptions=size=75%%,mode=1777\n" | $SUDO tee /etc/systemd/system/tmp.mount.d/override.conf

# "Enabling cgroup management from containers"
setsebool -P container_manage_cgroup true
fi