Skip to content

Commit 2e81f21

Browse files
committed
Integration in-container: simplify job
Signed-off-by: apostasie <[email protected]>
1 parent e64dc6b commit 2e81f21

File tree

2 files changed

+6
-11
lines changed

2 files changed

+6
-11
lines changed

.github/workflows/job-test-in-container.yml

Lines changed: 5 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,11 @@ jobs:
5656
run:
5757
shell: bash
5858

59+
env:
60+
# https://github.com/containerd/nerdctl/issues/622
61+
# The only case when rootlesskit-version is force-specified is when we downgrade explicitly to v1
62+
WORKAROUND_ISSUE_622: ${{ inputs.rootlesskit-version }}
63+
5964
steps:
6065
- name: "Init: checkout"
6166
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
@@ -137,16 +142,6 @@ jobs:
137142
sudo mkdir -p /etc/docker
138143
echo '{"ipv6": true, "fixed-cidr-v6": "2001:db8:1::/64", "experimental": true, "ip6tables": true}' | sudo tee /etc/docker/daemon.json
139144
sudo systemctl restart docker
140-
# Rootless with old rootlesskit wants to disable buildkit
141-
- if: ${{ inputs.target != 'rootful' && inputs.rootlesskit-version != '' }}
142-
name: "Init: disable buildkit for old rootlesskit"
143-
run: |
144-
# https://github.com/containerd/nerdctl/issues/622
145-
WORKAROUND_ISSUE_622=
146-
if echo "${ROOTLESSKIT_VERSION}" | grep -q v1; then
147-
WORKAROUND_ISSUE_622=1
148-
fi
149-
echo "WORKAROUND_ISSUE_622=$WORKAROUND_ISSUE_622" >> "$GITHUB_ENV"
150145
- name: "Run: integration tests"
151146
run: |
152147
. ./hack/github/action-helpers.sh

Dockerfile.d/test-integration-rootless.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ if [[ "$(id -u)" = "0" ]]; then
2626
fi
2727

2828
: "${WORKAROUND_ISSUE_622:=}"
29-
if [[ "$WORKAROUND_ISSUE_622" = "1" ]]; then
29+
if [[ "$WORKAROUND_ISSUE_622" != "" ]]; then
3030
touch /workaround-issue-622
3131
fi
3232

0 commit comments

Comments
 (0)