-
Notifications
You must be signed in to change notification settings - Fork 356
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Release: https://github.com/GoogleContainerTools/rules_distroless/releases/tag/v0.4.0 _Automated by [Publish to BCR](https://github.com/apps/publish-to-bcr)_ Co-authored-by: publish-to-bcr-bot <112732530+publish-to-bcr-bot[bot]@users.noreply.github.com>
- Loading branch information
1 parent
3b3ac69
commit 5cf8f00
Showing
5 changed files
with
126 additions
and
1 deletion.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,88 @@ | ||
"Bazel dependencies" | ||
|
||
module( | ||
name = "rules_distroless", | ||
version = "0.4.0", | ||
compatibility_level = 1, | ||
) | ||
|
||
# Bazel 8 fails without a working version of protobuf | ||
bazel_dep(name = "protobuf", version = "29.0-rc2.bcr.1") | ||
bazel_dep(name = "bazel_skylib", version = "1.5.0") | ||
bazel_dep(name = "aspect_bazel_lib", version = "2.9.4") | ||
bazel_dep(name = "rules_java", version = "8.3.2") | ||
|
||
bazel_lib_toolchains = use_extension("@aspect_bazel_lib//lib:extensions.bzl", "toolchains") | ||
use_repo(bazel_lib_toolchains, "zstd_toolchains") | ||
use_repo(bazel_lib_toolchains, "bsd_tar_toolchains") | ||
use_repo(bazel_lib_toolchains, "yq_darwin_amd64") | ||
use_repo(bazel_lib_toolchains, "yq_darwin_arm64") | ||
use_repo(bazel_lib_toolchains, "yq_linux_amd64") | ||
use_repo(bazel_lib_toolchains, "yq_linux_arm64") | ||
use_repo(bazel_lib_toolchains, "yq_linux_ppc64le") | ||
use_repo(bazel_lib_toolchains, "yq_linux_s390x") | ||
use_repo(bazel_lib_toolchains, "yq_windows_amd64") | ||
|
||
# Dev dependencies | ||
bazel_dep(name = "gazelle", version = "0.34.0", dev_dependency = True, repo_name = "bazel_gazelle") | ||
bazel_dep(name = "bazel_skylib_gazelle_plugin", version = "1.5.0", dev_dependency = True) | ||
bazel_dep(name = "buildifier_prebuilt", version = "6.1.2", dev_dependency = True) | ||
bazel_dep(name = "platforms", version = "0.0.10", dev_dependency = True) | ||
bazel_dep(name = "rules_oci", version = "2.0.0-rc0", dev_dependency = True) | ||
bazel_dep(name = "container_structure_test", version = "1.16.0", dev_dependency = True) | ||
bazel_dep(name = "bazel_features", version = "1.20.0", dev_dependency = True) | ||
|
||
http_archive = use_repo_rule("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive") | ||
|
||
http_archive( | ||
name = "example-bullseye-ca-certificates", | ||
build_file_content = 'exports_files(["data.tar.xz", "control.tar.xz"])', | ||
sha256 = "b2d488ad4d8d8adb3ba319fc9cb2cf9909fc42cb82ad239a26c570a2e749c389", | ||
urls = ["https://snapshot.debian.org/archive/debian/20231106T210201Z/pool/main/c/ca-certificates/ca-certificates_20210119_all.deb"], | ||
) | ||
|
||
http_archive( | ||
name = "example-bullseye-libc-bin", | ||
build_file_content = 'exports_files(["data.tar.xz"])', | ||
sha256 = "8b048ab5c7e9f5b7444655541230e689631fd9855c384e8c4a802586d9bbc65a", | ||
urls = ["https://snapshot.debian.org/archive/debian-security/20231106T230332Z/pool/updates/main/g/glibc/libc-bin_2.31-13+deb11u7_amd64.deb"], | ||
) | ||
|
||
http_archive( | ||
name = "example-bookworm-libc-bin", | ||
build_file_content = 'exports_files(["data.tar.xz"])', | ||
sha256 = "38c44247c5b3e864d6db2877edd9c9a0555fc4e23ae271b73d7f527802616df5", | ||
urls = ["https://snapshot.debian.org/archive/debian-security/20231106T230332Z/pool/updates/main/g/glibc/libc-bin_2.36-9+deb12u3_armhf.deb"], | ||
) | ||
|
||
apt = use_extension( | ||
"@rules_distroless//apt:extensions.bzl", | ||
"apt", | ||
dev_dependency = True, | ||
) | ||
apt.install( | ||
name = "bullseye", | ||
lock = "//examples/debian_snapshot:bullseye.lock.json", | ||
manifest = "//examples/debian_snapshot:bullseye.yaml", | ||
) | ||
apt.install( | ||
name = "bullseye_nolock", | ||
manifest = "//examples/debian_snapshot:bullseye_nolock.yaml", | ||
nolock = True, | ||
) | ||
apt.install( | ||
name = "apt_security", | ||
manifest = "//examples/debian_snapshot_security:security.yaml", | ||
nolock = True, | ||
) | ||
apt.install( | ||
name = "shared_dependencies", | ||
lock = "//examples/debian_shared_dependencies:bullseye.lock.json", | ||
manifest = "//examples/debian_shared_dependencies:bullseye.yaml", | ||
) | ||
apt.install( | ||
name = "noble", | ||
lock = "//examples/ubuntu_snapshot:noble.lock.json", | ||
manifest = "//examples/ubuntu_snapshot:noble.yaml", | ||
) | ||
use_repo(apt, "apt_security", "apt_security_resolve", "bullseye", "bullseye_nolock", "noble", "shared_dependencies") |
14 changes: 14 additions & 0 deletions
14
modules/rules_distroless/0.4.0/patches/module_dot_bazel_version.patch
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,14 @@ | ||
=================================================================== | ||
--- a/MODULE.bazel | ||
+++ b/MODULE.bazel | ||
@@ -1,9 +1,9 @@ | ||
"Bazel dependencies" | ||
|
||
module( | ||
name = "rules_distroless", | ||
- version = "0.0.0", | ||
+ version = "0.4.0", | ||
compatibility_level = 1, | ||
) | ||
|
||
# Bazel 8 fails without a working version of protobuf |
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,13 @@ | ||
bcr_test_module: | ||
module_path: "e2e/smoke" | ||
matrix: | ||
platform: ["debian10", "macos", "ubuntu2004"] | ||
# last_rc is to get latest 8.x release. Replace with 8.x when available. | ||
bazel: [7.x, last_rc] | ||
tasks: | ||
run_tests: | ||
name: "Run test module" | ||
bazel: ${{ bazel }} | ||
platform: ${{ platform }} | ||
test_targets: | ||
- "//..." |
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,9 @@ | ||
{ | ||
"integrity": "sha256-BcYKs40as0VtMIkiVrfMVQWZM7obvlsr5PsjJ4jhB/0=", | ||
"strip_prefix": "rules_distroless-0.4.0", | ||
"url": "https://github.com/GoogleContainerTools/rules_distroless/releases/download/v0.4.0/rules_distroless-v0.4.0.tar.gz", | ||
"patches": { | ||
"module_dot_bazel_version.patch": "sha256-lVdrOHNzwRnwjMXN/aI0mxnd4/YUUxHZqLyW0dXzjKQ=" | ||
}, | ||
"patch_strip": 1 | ||
} |
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 |
---|---|---|
|
@@ -26,7 +26,8 @@ | |
"0.3.2", | ||
"0.3.3", | ||
"0.3.7", | ||
"0.3.8" | ||
"0.3.8", | ||
"0.4.0" | ||
], | ||
"yanked_versions": {} | ||
} |