Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ci(criu): add CRIU PPA for Podman dependency (backport #770) #771

Merged
merged 3 commits into from
Jan 7, 2025
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
16 changes: 3 additions & 13 deletions .github/workflows/pr-ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,6 @@ on:
types:
- created

env:
OPENSUSE_UNOFFICIAL_LIBCONTAINERS_KEY_URL: "https://download.opensuse.org/repositories/devel:/kubic:/libcontainers:/unstable/xUbuntu_22.04/Release.key"
OPENSUSE_UNOFFICIAL_LIBCONTAINERS_SOURCE_URL: "https://download.opensuse.org/repositories/devel:/kubic:/libcontainers:/unstable/xUbuntu_22.04"

jobs:
check-before-build:
runs-on: ubuntu-latest
Expand Down Expand Up @@ -134,18 +130,12 @@ jobs:
cd src/main/webui
yarn install && yarn yarn:frzinstall
cd -
- name: Add CRIU PPA
run: sudo add-apt-repository ppa:criu/ppa && sudo apt update
- name: Install podman v4
run: |
echo "deb $OPENSUSE_UNOFFICIAL_LIBCONTAINERS_SOURCE_URL/ /" | sudo tee /etc/apt/sources.list.d/devel:kubic:libcontainers:unstable.list
curl -fsSL $OPENSUSE_UNOFFICIAL_LIBCONTAINERS_KEY_URL | gpg --dearmor | sudo tee /etc/apt/trusted.gpg.d/devel_kubic_libcontainers_unstable.gpg > /dev/null
sudo apt -y purge podman
sudo apt update && sudo apt -y install podman
- name: Emulate docker with podman
run: |
mkdir -p $HOME/.bin
cat <(echo '#!/usr/bin/env bash') <(echo 'exec podman "$@"') > $HOME/.bin/docker
chmod +x $HOME/.bin/docker
echo "PATH=$HOME/.bin:$PATH" >> "$GITHUB_ENV"
sudo apt update && sudo apt -y satisfy "podman (>= 4.0), podman-docker"
- name: Set up testcontainers for podman
run: |
echo ryuk.container.privileged=true > ~/.testcontainers.properties
Expand Down
20 changes: 4 additions & 16 deletions .github/workflows/push-ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,6 @@ on:
- cryostat-v[0-9]+.[0-9]+

env:
OPENSUSE_UNOFFICIAL_LIBCONTAINERS_KEY_URL: "https://download.opensuse.org/repositories/devel:/kubic:/libcontainers:/unstable/xUbuntu_22.04/Release.key"
OPENSUSE_UNOFFICIAL_LIBCONTAINERS_SOURCE_URL: "https://download.opensuse.org/repositories/devel:/kubic:/libcontainers:/unstable/xUbuntu_22.04"
CI_USER: cryostat+bot
CI_REGISTRY: quay.io/cryostat
CI_IMG: quay.io/cryostat/cryostat
Expand Down Expand Up @@ -55,10 +53,12 @@ jobs:
contents: read
if: ${{ github.repository_owner == 'cryostatio' }}
steps:
- name: Install qemu
- name: Add CRIU PPA
run: sudo add-apt-repository ppa:criu/ppa && sudo apt update
- name: Install podman 4 and qemu
run: |
sudo apt-get update
sudo apt-get install -y qemu-user-static
sudo apt -y satisfy "podman (>= 4.0), qemu-user-static, podman-docker"
- uses: actions/checkout@v3
with:
submodules: true
Expand All @@ -83,18 +83,6 @@ jobs:
cd src/main/webui
yarn install && yarn yarn:frzinstall
cd -
- name: Install podman v4
run: |
echo "deb $OPENSUSE_UNOFFICIAL_LIBCONTAINERS_SOURCE_URL/ /" | sudo tee /etc/apt/sources.list.d/devel:kubic:libcontainers:unstable.list
curl -fsSL $OPENSUSE_UNOFFICIAL_LIBCONTAINERS_KEY_URL | gpg --dearmor | sudo tee /etc/apt/trusted.gpg.d/devel_kubic_libcontainers_unstable.gpg > /dev/null
sudo apt -y purge podman
sudo apt update && sudo apt -y install podman
- name: Emulate docker with podman
run: |
mkdir -p $HOME/.bin
cat <(echo '#!/usr/bin/env bash') <(echo 'exec podman "$@"') > $HOME/.bin/docker
chmod +x $HOME/.bin/docker
echo "PATH=$HOME/.bin:$PATH" >> "$GITHUB_ENV"
- name: Set up testcontainers for podman
run: |
echo ryuk.container.privileged=true > ~/.testcontainers.properties
Expand Down
Loading