Skip to content

Commit ddda123

Browse files
committed
ci: enable v6 install from r2 test
Signed-off-by: Daijiro Fukuda <[email protected]>
1 parent c7cac9d commit ddda123

File tree

4 files changed

+88
-12
lines changed

4 files changed

+88
-12
lines changed

.github/workflows/yum.yml

Lines changed: 61 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -377,7 +377,7 @@ jobs:
377377
run: fluent-package/yum/systemd-test/test.sh ${{ matrix.test-incus-image }} ${{ matrix.test }}
378378

379379
fluent-release-test:
380-
name: Test ${{ matrix.label }} ${{ matrix.test }} (CGroup V2)
380+
name: Test ${{ matrix.label }} ${{ matrix.test }} (Normal) (CGroup V2)
381381
needs: [define-matrix, v2test]
382382
runs-on: ubuntu-latest
383383
timeout-minutes: 15
@@ -387,7 +387,21 @@ jobs:
387387
label: ${{ fromJSON(needs.define-matrix.outputs.label) }}
388388
test:
389389
- install-from-r2.sh
390+
- install-from-r2.sh from-v4
391+
- install-from-r2.sh from-v5
392+
- install-from-r2.sh from-v5-v4
390393
include: ${{ fromJSON(needs.define-matrix.outputs.matrix).include }}
394+
exclude:
395+
- label: Amazon Linux 2023 x86_64
396+
test: install-from-r2.sh from-v4
397+
- label: Amazon Linux 2023 x86_64
398+
test: install-from-r2.sh from-v5-v4
399+
- label: AlmaLinux 10 x86_64
400+
test: install-from-r2.sh from-v4
401+
- label: AlmaLinux 10 x86_64
402+
test: install-from-r2.sh from-v5-v4
403+
- label: AlmaLinux 10 x86_64
404+
test: install-from-r2.sh from-v5
391405
steps:
392406
- uses: actions/checkout@v4
393407
- uses: actions/download-artifact@v4
@@ -406,6 +420,50 @@ jobs:
406420
run: |
407421
sudo incus admin init --auto
408422
- name: Run Test ${{matrix.test}} on ${{ matrix.test-incus-image }}
409-
# There are no released for AlmaLinux 10 x86_64 yet
410-
if: ${{ matrix.label != 'AlmaLinux 10 x86_64' }}
411423
run: fluent-release/yum/systemd-test/test.sh ${{ matrix.test-incus-image }} ${{ matrix.test }}
424+
425+
fluent-lts-release-test:
426+
name: Test ${{ matrix.label }} ${{ matrix.test }} (LTS) (CGroup V2)
427+
needs: [define-matrix, v2test]
428+
runs-on: ubuntu-latest
429+
timeout-minutes: 15
430+
strategy:
431+
fail-fast: false
432+
matrix:
433+
label: ${{ fromJSON(needs.define-matrix.outputs.label) }}
434+
test:
435+
- install-from-r2.sh
436+
- install-from-r2.sh from-v4
437+
- install-from-r2.sh from-v5
438+
- install-from-r2.sh from-v5-v4
439+
include: ${{ fromJSON(needs.define-matrix.outputs.matrix).include }}
440+
exclude:
441+
- label: Amazon Linux 2023 x86_64
442+
test: install-from-r2.sh from-v4
443+
- label: Amazon Linux 2023 x86_64
444+
test: install-from-r2.sh from-v5-v4
445+
- label: AlmaLinux 10 x86_64
446+
test: install-from-r2.sh from-v4
447+
- label: AlmaLinux 10 x86_64
448+
test: install-from-r2.sh from-v5-v4
449+
- label: AlmaLinux 10 x86_64
450+
test: install-from-r2.sh from-v5
451+
steps:
452+
- uses: actions/checkout@v4
453+
- uses: actions/download-artifact@v4
454+
with:
455+
name: packages-lts-release-${{ matrix.rake-job }}
456+
- name: Install Incus
457+
run: |
458+
sudo apt-get update
459+
sudo apt-get install -y -V incus
460+
- name: Allow egress network traffic flows for Incus
461+
# https://linuxcontainers.org/incus/docs/main/howto/network_bridge_firewalld/#prevent-connectivity-issues-with-incus-and-docker
462+
run: |
463+
sudo iptables -I DOCKER-USER -i incusbr0 -j ACCEPT
464+
sudo iptables -I DOCKER-USER -o incusbr0 -m conntrack --ctstate RELATED,ESTABLISHED -j ACCEPT
465+
- name: Setup Incus
466+
run: |
467+
sudo incus admin init --auto
468+
- name: Run Test ${{matrix.test}} on ${{ matrix.test-incus-image }}
469+
run: fluent-lts-release/yum/systemd-test/test.sh ${{ matrix.test-incus-image }} ${{ matrix.test }}

fluent-lts-release/yum/systemd-test/install-from-r2.sh

Lines changed: 13 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,17 @@ set -exu
44

55
. $(dirname $0)/../../../fluent-package/yum/systemd-test/common.sh
66

7+
testcase="${1:-new}" # new / from-v5 / from-v4 / from-v5-v4
8+
9+
if [ "$testcase" = from-v4 ]; then
10+
install_v4
11+
elif [ "$testcase" = from-v5 ]; then
12+
install_v5_lts
13+
elif [ "$testcase" = from-v5-v4 ]; then
14+
install_v4
15+
install_v5_lts
16+
fi
17+
718
sudo $DNF install -y \
819
/host/${distribution}/${DISTRIBUTION_VERSION}/x86_64/Packages/fluent-lts-release-*.noarch.rpm
920

@@ -15,9 +26,7 @@ grep fluentd.cdn.cncf.io /etc/yum.repos.d/fluent-package-lts.repo
1526
test $($DNF repolist --enabled | grep 'Fluentd Project' | wc -l) -eq 1
1627
test $($DNF repolist --enabled | grep 'Fluentd Project' | cut -d' ' -f1) = fluent-package-v6-lts
1728

18-
# TODO: v6 package was released, remove it and test with v6
19-
sudo $DNF config-manager --disable fluent-package-v6-lts
20-
sudo $DNF config-manager --enable fluent-package-v5-lts
21-
2229
sudo $DNF update -y
2330
sudo $DNF install -y fluent-package
31+
32+
test "$(fluentd --version)" = "fluent-package 6.0.0 fluentd 1.19.0 (ed15edc4b7c86c1fcea3fbf326b7c42325e6fc71)"

fluent-lts-release/yum/systemd-test/test.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ image=$1
1010
test_file=$2
1111
shift 2
1212
other_args="$@"
13-
dir="/host/fluent-release/yum/systemd-test"
13+
dir="/host/fluent-lts-release/yum/systemd-test"
1414

1515
set -eux
1616

fluent-release/yum/systemd-test/install-from-r2.sh

Lines changed: 13 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,17 @@ set -exu
44

55
. $(dirname $0)/../../../fluent-package/yum/systemd-test/common.sh
66

7+
testcase="${1:-new}" # new / from-v5 / from-v4 / from-v5-v4
8+
9+
if [ "$testcase" = from-v4 ]; then
10+
install_v4
11+
elif [ "$testcase" = from-v5 ]; then
12+
install_v5
13+
elif [ "$testcase" = from-v5-v4 ]; then
14+
install_v4
15+
install_v5
16+
fi
17+
718
sudo $DNF install -y \
819
/host/${distribution}/${DISTRIBUTION_VERSION}/x86_64/Packages/fluent-release-*.noarch.rpm
920

@@ -15,9 +26,7 @@ grep fluentd.cdn.cncf.io /etc/yum.repos.d/fluent-package.repo
1526
test $($DNF repolist --enabled | grep 'Fluentd Project' | wc -l) -eq 1
1627
test $($DNF repolist --enabled | grep 'Fluentd Project' | cut -d' ' -f1) = fluent-package-v6
1728

18-
# TODO: v6 package was released, remove it and test with v6
19-
sudo $DNF config-manager --disable fluent-package-v6
20-
sudo $DNF config-manager --enable fluent-package-v5
21-
2229
sudo $DNF update -y
2330
sudo $DNF install -y fluent-package
31+
32+
test "$(fluentd --version)" = "fluent-package 6.0.0 fluentd 1.19.0 (ed15edc4b7c86c1fcea3fbf326b7c42325e6fc71)"

0 commit comments

Comments
 (0)