Skip to content

Commit

Permalink
arm64 support for sidecar-shim in bazel
Browse files Browse the repository at this point in the history
Signed-off-by: Dharmit Shah <shahdharmit@gmail.com>
  • Loading branch information
dharmit committed Oct 19, 2023
1 parent ed99ca8 commit cb461a2
Show file tree
Hide file tree
Showing 3 changed files with 147 additions and 74 deletions.
11 changes: 8 additions & 3 deletions cmd/sidecars/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,13 @@ container_image(
directory = "/",
entrypoint = ["/sidecar-shim"],
files = [":sidecar-shim"],
tars = [
"//rpm:sidecar-shim_x86_64",
],
tars = select({
"@io_bazel_rules_go//go/platform:linux_arm64": [
"//rpm:sidecar-shim_aarch64",
],
"//conditions:default": [
"//rpm:sidecar-shim_x86_64",
],
}),
visibility = ["//visibility:public"],
)
2 changes: 1 addition & 1 deletion hack/bootstrap.sh
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ KUBEVIRT_NO_BAZEL=${KUBEVIRT_NO_BAZEL:-false}
HOST_ARCHITECTURE="$(uname -m)"

sandbox_root=${SANDBOX_DIR}/default/root
sandbox_hash="c0517e572c0a096fa3d3e52fdd51ccf11da1bee0"
sandbox_hash="1af5e1ff64f2b4304f351f114fb43999dbd3a325"

function kubevirt::bootstrap::regenerate() {
(
Expand Down
208 changes: 138 additions & 70 deletions rpm/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -159,76 +159,6 @@ rpmtree(
visibility = ["//visibility:public"],
)

rpmtree(
name = "sidecar-shim_x86_64",
rpms = [
"@acl-0__2.3.1-3.el9.x86_64//rpm",
"@alternatives-0__1.24-1.el9.x86_64//rpm",
"@basesystem-0__11-13.el9.x86_64//rpm",
"@bash-0__5.1.8-6.el9.x86_64//rpm",
"@bzip2-libs-0__1.0.8-8.el9.x86_64//rpm",
"@ca-certificates-0__2023.2.60_v7.0.306-90.1.el9.x86_64//rpm",
"@centos-gpg-keys-0__9.0-23.el9.x86_64//rpm",
"@centos-stream-release-0__9.0-23.el9.x86_64//rpm",
"@centos-stream-repos-0__9.0-23.el9.x86_64//rpm",
"@coreutils-single-0__8.32-34.el9.x86_64//rpm",
"@crypto-policies-0__20230731-1.git94f0e2c.el9.x86_64//rpm",
"@curl-minimal-0__7.76.1-26.el9.x86_64//rpm",
"@expat-0__2.5.0-1.el9.x86_64//rpm",
"@filesystem-0__3.16-2.el9.x86_64//rpm",
"@gawk-0__5.1.0-6.el9.x86_64//rpm",
"@gdbm-libs-1__1.19-4.el9.x86_64//rpm",
"@glibc-0__2.34-82.el9.x86_64//rpm",
"@glibc-common-0__2.34-82.el9.x86_64//rpm",
"@glibc-langpack-raj-0__2.34-82.el9.x86_64//rpm",
"@gmp-1__6.2.0-13.el9.x86_64//rpm",
"@grep-0__3.6-5.el9.x86_64//rpm",
"@keyutils-libs-0__1.6.3-1.el9.x86_64//rpm",
"@krb5-libs-0__1.21.1-1.el9.x86_64//rpm",
"@libacl-0__2.3.1-3.el9.x86_64//rpm",
"@libattr-0__2.5.1-3.el9.x86_64//rpm",
"@libcap-0__2.48-9.el9.x86_64//rpm",
"@libcom_err-0__1.46.5-3.el9.x86_64//rpm",
"@libcurl-minimal-0__7.76.1-26.el9.x86_64//rpm",
"@libffi-0__3.4.2-8.el9.x86_64//rpm",
"@libgcc-0__11.4.1-2.1.el9.x86_64//rpm",
"@libnghttp2-0__1.43.0-5.el9.x86_64//rpm",
"@libselinux-0__3.5-1.el9.x86_64//rpm",
"@libsepol-0__3.5-1.el9.x86_64//rpm",
"@libsigsegv-0__2.13-4.el9.x86_64//rpm",
"@libtasn1-0__4.16.0-8.el9.x86_64//rpm",
"@libuuid-0__2.37.4-15.el9.x86_64//rpm",
"@libverto-0__0.3.2-3.el9.x86_64//rpm",
"@libxcrypt-0__4.4.18-3.el9.x86_64//rpm",
"@mpfr-0__4.1.0-7.el9.x86_64//rpm",
"@ncurses-base-0__6.2-10.20210508.el9.x86_64//rpm",
"@ncurses-libs-0__6.2-10.20210508.el9.x86_64//rpm",
"@openssl-libs-1__3.0.7-24.el9.x86_64//rpm",
"@p11-kit-0__0.24.1-2.el9.x86_64//rpm",
"@p11-kit-trust-0__0.24.1-2.el9.x86_64//rpm",
"@pcre-0__8.44-3.el9.3.x86_64//rpm",
"@pcre2-0__10.40-2.el9.x86_64//rpm",
"@pcre2-syntax-0__10.40-2.el9.x86_64//rpm",
"@python3-0__3.9.17-2.el9.x86_64//rpm",
"@python3-libs-0__3.9.17-2.el9.x86_64//rpm",
"@python3-pip-wheel-0__21.2.3-7.el9.x86_64//rpm",
"@python3-setuptools-wheel-0__53.0.0-12.el9.x86_64//rpm",
"@readline-0__8.1-4.el9.x86_64//rpm",
"@sed-0__4.8-9.el9.x86_64//rpm",
"@setup-0__2.13.7-9.el9.x86_64//rpm",
"@sqlite-libs-0__3.34.1-6.el9.x86_64//rpm",
"@tzdata-0__2023c-1.el9.x86_64//rpm",
"@vim-minimal-2__8.2.2637-20.el9.x86_64//rpm",
"@xz-libs-0__5.2.5-8.el9.x86_64//rpm",
"@zlib-0__1.2.11-40.el9.x86_64//rpm",
],
symlinks = {
"/usr/bin/python": "/usr/bin/python3.9",
"/usr/bin/python3": "/usr/bin/python3.9",
},
visibility = ["//visibility:public"],
)

rpmtree(
name = "handlerbase_aarch64",
rpms = [
Expand Down Expand Up @@ -1795,6 +1725,144 @@ rpmtree(
visibility = ["//visibility:public"],
)

rpmtree(
name = "sidecar-shim_aarch64",
rpms = [
"@acl-0__2.3.1-3.el9.aarch64//rpm",
"@alternatives-0__1.24-1.el9.aarch64//rpm",
"@basesystem-0__11-13.el9.aarch64//rpm",
"@bash-0__5.1.8-6.el9.aarch64//rpm",
"@bzip2-libs-0__1.0.8-8.el9.aarch64//rpm",
"@ca-certificates-0__2023.2.60_v7.0.306-90.1.el9.aarch64//rpm",
"@centos-gpg-keys-0__9.0-23.el9.aarch64//rpm",
"@centos-stream-release-0__9.0-23.el9.aarch64//rpm",
"@centos-stream-repos-0__9.0-23.el9.aarch64//rpm",
"@coreutils-single-0__8.32-34.el9.aarch64//rpm",
"@crypto-policies-0__20230920-1.git8dcf74d.el9.aarch64//rpm",
"@curl-minimal-0__7.76.1-28.el9.aarch64//rpm",
"@expat-0__2.5.0-1.el9.aarch64//rpm",
"@filesystem-0__3.16-2.el9.aarch64//rpm",
"@gawk-0__5.1.0-6.el9.aarch64//rpm",
"@gdbm-libs-1__1.19-4.el9.aarch64//rpm",
"@glibc-0__2.34-83.el9.7.aarch64//rpm",
"@glibc-common-0__2.34-83.el9.7.aarch64//rpm",
"@gmp-1__6.2.0-13.el9.aarch64//rpm",
"@grep-0__3.6-5.el9.aarch64//rpm",
"@keyutils-libs-0__1.6.3-1.el9.aarch64//rpm",
"@krb5-libs-0__1.21.1-1.el9.aarch64//rpm",
"@libacl-0__2.3.1-3.el9.aarch64//rpm",
"@libattr-0__2.5.1-3.el9.aarch64//rpm",
"@libcap-0__2.48-9.el9.aarch64//rpm",
"@libcom_err-0__1.46.5-3.el9.aarch64//rpm",
"@libcurl-minimal-0__7.76.1-28.el9.aarch64//rpm",
"@libffi-0__3.4.2-8.el9.aarch64//rpm",
"@libgcc-0__11.4.1-2.3.el9.aarch64//rpm",
"@libnghttp2-0__1.43.0-5.el9.aarch64//rpm",
"@libselinux-0__3.5-1.el9.aarch64//rpm",
"@libsepol-0__3.5-1.el9.aarch64//rpm",
"@libsigsegv-0__2.13-4.el9.aarch64//rpm",
"@libtasn1-0__4.16.0-8.el9.aarch64//rpm",
"@libuuid-0__2.37.4-15.el9.aarch64//rpm",
"@libverto-0__0.3.2-3.el9.aarch64//rpm",
"@libxcrypt-0__4.4.18-3.el9.aarch64//rpm",
"@mpfr-0__4.1.0-7.el9.aarch64//rpm",
"@ncurses-base-0__6.2-10.20210508.el9.aarch64//rpm",
"@ncurses-libs-0__6.2-10.20210508.el9.aarch64//rpm",
"@openssl-libs-1__3.0.7-24.el9.aarch64//rpm",
"@p11-kit-0__0.24.1-2.el9.aarch64//rpm",
"@p11-kit-trust-0__0.24.1-2.el9.aarch64//rpm",
"@pcre-0__8.44-3.el9.3.aarch64//rpm",
"@pcre2-0__10.40-2.el9.aarch64//rpm",
"@pcre2-syntax-0__10.40-2.el9.aarch64//rpm",
"@python3-0__3.9.17-2.el9.aarch64//rpm",
"@python3-libs-0__3.9.17-2.el9.aarch64//rpm",
"@python3-pip-wheel-0__21.2.3-7.el9.aarch64//rpm",
"@python3-setuptools-wheel-0__53.0.0-12.el9.aarch64//rpm",
"@readline-0__8.1-4.el9.aarch64//rpm",
"@sed-0__4.8-9.el9.aarch64//rpm",
"@setup-0__2.13.7-9.el9.aarch64//rpm",
"@sqlite-libs-0__3.34.1-6.el9.aarch64//rpm",
"@tzdata-0__2023c-1.el9.aarch64//rpm",
"@vim-minimal-2__8.2.2637-20.el9.aarch64//rpm",
"@xz-libs-0__5.2.5-8.el9.aarch64//rpm",
"@zlib-0__1.2.11-40.el9.aarch64//rpm",
],
symlinks = {
"/usr/bin/python": "/usr/bin/python3.9",
"/usr/bin/python3": "/usr/bin/python3.9",
},
visibility = ["//visibility:public"],
)

rpmtree(
name = "sidecar-shim_x86_64",
rpms = [
"@acl-0__2.3.1-3.el9.x86_64//rpm",
"@alternatives-0__1.24-1.el9.x86_64//rpm",
"@basesystem-0__11-13.el9.x86_64//rpm",
"@bash-0__5.1.8-6.el9.x86_64//rpm",
"@bzip2-libs-0__1.0.8-8.el9.x86_64//rpm",
"@ca-certificates-0__2023.2.60_v7.0.306-90.1.el9.x86_64//rpm",
"@centos-gpg-keys-0__9.0-23.el9.x86_64//rpm",
"@centos-stream-release-0__9.0-23.el9.x86_64//rpm",
"@centos-stream-repos-0__9.0-23.el9.x86_64//rpm",
"@coreutils-single-0__8.32-34.el9.x86_64//rpm",
"@crypto-policies-0__20230920-1.git8dcf74d.el9.x86_64//rpm",
"@curl-minimal-0__7.76.1-28.el9.x86_64//rpm",
"@expat-0__2.5.0-1.el9.x86_64//rpm",
"@filesystem-0__3.16-2.el9.x86_64//rpm",
"@gawk-0__5.1.0-6.el9.x86_64//rpm",
"@gdbm-libs-1__1.19-4.el9.x86_64//rpm",
"@glibc-0__2.34-83.el9.7.x86_64//rpm",
"@glibc-common-0__2.34-83.el9.7.x86_64//rpm",
"@gmp-1__6.2.0-13.el9.x86_64//rpm",
"@grep-0__3.6-5.el9.x86_64//rpm",
"@keyutils-libs-0__1.6.3-1.el9.x86_64//rpm",
"@krb5-libs-0__1.21.1-1.el9.x86_64//rpm",
"@libacl-0__2.3.1-3.el9.x86_64//rpm",
"@libattr-0__2.5.1-3.el9.x86_64//rpm",
"@libcap-0__2.48-9.el9.x86_64//rpm",
"@libcom_err-0__1.46.5-3.el9.x86_64//rpm",
"@libcurl-minimal-0__7.76.1-28.el9.x86_64//rpm",
"@libffi-0__3.4.2-8.el9.x86_64//rpm",
"@libgcc-0__11.4.1-2.3.el9.x86_64//rpm",
"@libnghttp2-0__1.43.0-5.el9.x86_64//rpm",
"@libselinux-0__3.5-1.el9.x86_64//rpm",
"@libsepol-0__3.5-1.el9.x86_64//rpm",
"@libsigsegv-0__2.13-4.el9.x86_64//rpm",
"@libtasn1-0__4.16.0-8.el9.x86_64//rpm",
"@libuuid-0__2.37.4-15.el9.x86_64//rpm",
"@libverto-0__0.3.2-3.el9.x86_64//rpm",
"@libxcrypt-0__4.4.18-3.el9.x86_64//rpm",
"@mpfr-0__4.1.0-7.el9.x86_64//rpm",
"@ncurses-base-0__6.2-10.20210508.el9.x86_64//rpm",
"@ncurses-libs-0__6.2-10.20210508.el9.x86_64//rpm",
"@openssl-libs-1__3.0.7-24.el9.x86_64//rpm",
"@p11-kit-0__0.24.1-2.el9.x86_64//rpm",
"@p11-kit-trust-0__0.24.1-2.el9.x86_64//rpm",
"@pcre-0__8.44-3.el9.3.x86_64//rpm",
"@pcre2-0__10.40-2.el9.x86_64//rpm",
"@pcre2-syntax-0__10.40-2.el9.x86_64//rpm",
"@python3-0__3.9.17-2.el9.x86_64//rpm",
"@python3-libs-0__3.9.17-2.el9.x86_64//rpm",
"@python3-pip-wheel-0__21.2.3-7.el9.x86_64//rpm",
"@python3-setuptools-wheel-0__53.0.0-12.el9.x86_64//rpm",
"@readline-0__8.1-4.el9.x86_64//rpm",
"@sed-0__4.8-9.el9.x86_64//rpm",
"@setup-0__2.13.7-9.el9.x86_64//rpm",
"@sqlite-libs-0__3.34.1-6.el9.x86_64//rpm",
"@tzdata-0__2023c-1.el9.x86_64//rpm",
"@vim-minimal-2__8.2.2637-20.el9.x86_64//rpm",
"@xz-libs-0__5.2.5-8.el9.x86_64//rpm",
"@zlib-0__1.2.11-40.el9.x86_64//rpm",
],
symlinks = {
"/usr/bin/python": "/usr/bin/python3.9",
"/usr/bin/python3": "/usr/bin/python3.9",
},
visibility = ["//visibility:public"],
)

rpmtree(
name = "testimage_aarch64",
rpms = [
Expand Down

0 comments on commit cb461a2

Please sign in to comment.