mirror of
https://github.com/netbirdio/gvisor.git
synced 2026-05-22 17:12:49 -07:00
BUILD: Use runsc to generate version
This also ensures BUILD files are correctly formatted. PiperOrigin-RevId: 251990267
This commit is contained in:
+6
-4
@@ -1,6 +1,4 @@
|
||||
package(
|
||||
licenses = ["notice"], # Apache 2.0
|
||||
)
|
||||
package(licenses = ["notice"]) # Apache 2.0
|
||||
|
||||
load("@io_bazel_rules_go//go:def.bzl", "go_binary")
|
||||
load("@bazel_tools//tools/build_defs/pkg:pkg.bzl", "pkg_deb", "pkg_tar")
|
||||
@@ -84,8 +82,9 @@ pkg_tar(
|
||||
genrule(
|
||||
name = "deb-version",
|
||||
outs = ["version.txt"],
|
||||
cmd = "cat bazel-out/volatile-status.txt | grep VERSION | sed 's/^[^0-9]*//' >$@",
|
||||
cmd = "$(location :runsc) -version | head -n 1 | sed 's/^[^0-9]*//' > $@",
|
||||
stamp = 1,
|
||||
tools = [":runsc"],
|
||||
)
|
||||
|
||||
pkg_deb(
|
||||
@@ -98,4 +97,7 @@ pkg_deb(
|
||||
package = "runsc",
|
||||
postinst = "debian/postinst.sh",
|
||||
version_file = ":version.txt",
|
||||
visibility = [
|
||||
"//visibility:public",
|
||||
],
|
||||
)
|
||||
|
||||
+1
-5
@@ -1,8 +1,4 @@
|
||||
# gVisor is a general-purpose sandbox.
|
||||
|
||||
package(licenses = ["notice"])
|
||||
|
||||
exports_files(["LICENSE"])
|
||||
package(licenses = ["notice"]) # Apache 2.0
|
||||
|
||||
# We need to define a bazel platform and toolchain to specify dockerPrivileged
|
||||
# and dockerRunAsRoot options, they are required to run tests on the RBE
|
||||
|
||||
Reference in New Issue
Block a user