forked from antrea-io/antrea
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Upgrade base image of UBI to UBI9 (antrea-io#5737)
- Switch to centos:stream9 to build OVS - Use bind mount to reduce intermediate layers Signed-off-by: Xu Liu <xliu2@vmware.com>
- Loading branch information
1 parent
d8555ea
commit a3a7abb
Showing
9 changed files
with
126 additions
and
42 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,76 @@ | ||
name: Kind for UBI | ||
on: | ||
pull_request: | ||
branches: | ||
- main | ||
- release-* | ||
- feature/* | ||
push: | ||
branches: | ||
- main | ||
- release-* | ||
- feature/* | ||
|
||
jobs: | ||
check-changes: | ||
name: Check whether tests need to be run based on diff | ||
runs-on: [ubuntu-latest] | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
show-progress: false | ||
- uses: antrea-io/has-changes@v2 | ||
id: check_diff | ||
with: | ||
paths-ignore: docs/* ci/jenkins/* *.md hack/.notableofcontents plugins/* | ||
outputs: | ||
has_changes: ${{ steps.check_diff.outputs.has_changes }} | ||
|
||
build-and-test-ubi: | ||
needs: check-changes | ||
if: ${{ needs.check-changes.outputs.has_changes == 'yes' || github.event_name == 'push' }} | ||
runs-on: [ubuntu-latest] | ||
steps: | ||
- name: Free disk space | ||
# https://github.com/actions/virtual-environments/issues/709 | ||
run: | | ||
sudo apt-get clean | ||
df -h | ||
- uses: actions/checkout@v4 | ||
with: | ||
show-progress: false | ||
- name: Set up Docker Buildx | ||
uses: docker/setup-buildx-action@v3 | ||
- uses: actions/setup-go@v5 | ||
with: | ||
go-version-file: 'go.mod' | ||
- name: Build Antrea UBI9 Docker image | ||
run: | | ||
./hack/build-antrea-linux-all.sh --pull --distro ubi | ||
- name: Clean up docker build cache | ||
run: | | ||
docker builder prune -f | ||
- name: Install Kind | ||
run: | | ||
KIND_VERSION=$(head -n1 ./ci/kind/version) | ||
curl -Lo ./kind https://github.com/kubernetes-sigs/kind/releases/download/${KIND_VERSION}/kind-$(uname)-amd64 | ||
chmod +x ./kind | ||
sudo mv kind /usr/local/bin | ||
- name: Run basic e2e tests | ||
run: | | ||
mkdir log | ||
ANTREA_LOG_DIR=$PWD/log ./ci/kind/test-e2e-kind.sh --encap-mode encap \ | ||
--antrea-controller-image antrea/antrea-controller-ubi \ | ||
--antrea-agent-image antrea/antrea-agent-ubi \ | ||
--run '^TestBasic$' | ||
- name: Tar log files | ||
if: ${{ failure() }} | ||
run: tar -czf log.tar.gz log | ||
- name: Upload test log | ||
uses: actions/upload-artifact@v4 | ||
if: ${{ failure() }} | ||
with: | ||
name: e2e-kind-ubi-basic.tar.gz | ||
path: log.tar.gz | ||
retention-days: 30 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,27 @@ | ||
[AppStream] | ||
name=CentOS-8-stream - AppStream | ||
mirrorlist=http://mirrorlist.centos.org/?release=8-stream&arch=$basearch&repo=AppStream&infra=$infra | ||
#baseurl=http://mirror.centos.org/$contentdir/8-stream/AppStream/$basearch/os/ | ||
[appstream] | ||
name=CentOS Stream $releasever - AppStream | ||
metalink=https://mirrors.centos.org/metalink?repo=centos-appstream-9-stream&arch=$basearch&protocol=https,http | ||
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-centosofficial | ||
gpgcheck=1 | ||
enabled=1 | ||
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-centosofficial | ||
|
||
[BaseOS] | ||
name=CentOS-8-stream - Base | ||
mirrorlist=http://mirrorlist.centos.org/?release=8-stream&arch=$basearch&repo=BaseOS&infra=$infra | ||
#baseurl=http://mirror.centos.org/$contentdir/8-stream/BaseOS/$basearch/os/ | ||
[baseos] | ||
name=CentOS Stream $releasever - BaseOS | ||
metalink=https://mirrors.centos.org/metalink?repo=centos-baseos-9-stream&arch=$basearch&protocol=https,http | ||
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-centosofficial | ||
gpgcheck=1 | ||
enabled=1 | ||
|
||
[crb] | ||
name=CentOS Stream $releasever - CRB | ||
metalink=https://mirrors.centos.org/metalink?repo=centos-crb-9-stream&arch=$basearch&protocol=https,http | ||
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-centosofficial | ||
gpgcheck=1 | ||
enabled=1 | ||
|
||
[extras] | ||
name=CentOS-8-stream - Extras | ||
mirrorlist=http://mirrorlist.centos.org/?release=8-stream&arch=$basearch&repo=extras&infra=$infra | ||
#baseurl=http://mirror.centos.org/$contentdir/8-stream/extras/$basearch/os/ | ||
[extras-common] | ||
name=CentOS Stream $releasever - Extras packages | ||
metalink=https://mirrors.centos.org/metalink?repo=centos-extras-sig-extras-common-9-stream&arch=$basearch&protocol=https,http | ||
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-SIG-Extras | ||
gpgcheck=1 | ||
enabled=1 | ||
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-centosofficial |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters