mirror of https://github.com/k3s-io/k3s
add CNI_VERSION to build/workspace.bzl, use it to dedupe version
parent
8f7405ec92
commit
4cd93dada4
|
@ -89,12 +89,6 @@ grep ^STABLE_BUILD_SCM_REVISION bazel-out/stable-status.txt \
|
|||
stamp = 1,
|
||||
)
|
||||
|
||||
genrule(
|
||||
name = "cni_package_version",
|
||||
outs = ["cni_version"],
|
||||
cmd = "echo 0.6.0 >$@",
|
||||
)
|
||||
|
||||
release_filegroup(
|
||||
name = "docker-artifacts",
|
||||
srcs = [":%s.tar" % binary for binary in DOCKERIZED_BINARIES.keys()] +
|
||||
|
|
|
@ -3,7 +3,7 @@ package(default_visibility = ["//visibility:public"])
|
|||
load("@io_kubernetes_build//defs:deb.bzl", "k8s_deb", "deb_data")
|
||||
load("@io_kubernetes_build//defs:build.bzl", "release_filegroup")
|
||||
load("@io_kubernetes_build//defs:pkg.bzl", "pkg_tar")
|
||||
load("//build:workspace.bzl", "CRI_TOOLS_VERSION")
|
||||
load("//build:workspace.bzl", "CNI_VERSION", "CRI_TOOLS_VERSION")
|
||||
|
||||
# We do not include kube-scheduler, kube-controller-manager,
|
||||
# kube-apiserver, and kube-proxy in this list even though we
|
||||
|
@ -153,7 +153,7 @@ k8s_deb(
|
|||
"ethtool",
|
||||
"iproute2",
|
||||
"iptables (>= 1.4.21)",
|
||||
"kubernetes-cni (>= 0.6.0)",
|
||||
"kubernetes-cni (>= %s)" % CNI_VERSION,
|
||||
"mount",
|
||||
"socat",
|
||||
"util-linux",
|
||||
|
@ -169,7 +169,7 @@ k8s_deb(
|
|||
depends = [
|
||||
"kubelet (>= 1.8.0)",
|
||||
"kubectl (>= 1.8.0)",
|
||||
"kubernetes-cni (>= 0.6.0)",
|
||||
"kubernetes-cni (>= %s)" % CNI_VERSION,
|
||||
"cri-tools (>= 1.11.0)",
|
||||
],
|
||||
description = """Kubernetes Cluster Bootstrapping Tool
|
||||
|
@ -184,7 +184,7 @@ k8s_deb(
|
|||
description = """Kubernetes Packaging of CNI
|
||||
The Container Networking Interface tools for provisioning container networks.
|
||||
""",
|
||||
version_file = "//build:cni_package_version",
|
||||
version = CNI_VERSION,
|
||||
)
|
||||
|
||||
k8s_deb(
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive", "http_file")
|
||||
load("//build:workspace_mirror.bzl", "mirror")
|
||||
load("//build:workspace.bzl", "CRI_TOOLS_VERSION")
|
||||
load("//build:workspace.bzl", "CNI_VERSION", "CRI_TOOLS_VERSION")
|
||||
|
||||
http_archive(
|
||||
name = "io_bazel_rules_go",
|
||||
|
@ -58,7 +58,7 @@ http_file(
|
|||
name = "kubernetes_cni",
|
||||
downloaded_file_path = "kubernetes_cni.tgz",
|
||||
sha256 = "f04339a21b8edf76d415e7f17b620e63b8f37a76b2f706671587ab6464411f2d",
|
||||
urls = mirror("https://storage.googleapis.com/kubernetes-release/network-plugins/cni-plugins-amd64-v0.6.0.tgz"),
|
||||
urls = mirror("https://storage.googleapis.com/kubernetes-release/network-plugins/cni-plugins-amd64-v%s.tgz" % CNI_VERSION),
|
||||
)
|
||||
|
||||
http_file(
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
package(default_visibility = ["//visibility:public"])
|
||||
|
||||
load("@bazel_tools//tools/build_defs/pkg:rpm.bzl", "pkg_rpm")
|
||||
load("//build:workspace.bzl", "CRI_TOOLS_VERSION")
|
||||
load("//build:workspace.bzl", "CNI_VERSION", "CRI_TOOLS_VERSION")
|
||||
|
||||
filegroup(
|
||||
name = "rpms",
|
||||
|
@ -66,7 +66,7 @@ pkg_rpm(
|
|||
],
|
||||
spec_file = "kubernetes-cni.spec",
|
||||
tags = ["manual"],
|
||||
version_file = "//build:cni_package_version",
|
||||
version = CNI_VERSION,
|
||||
)
|
||||
|
||||
pkg_rpm(
|
||||
|
|
|
@ -13,3 +13,5 @@
|
|||
# limitations under the License.
|
||||
|
||||
CRI_TOOLS_VERSION = "1.12.0"
|
||||
|
||||
CNI_VERSION = "0.6.0"
|
||||
|
|
Loading…
Reference in New Issue