mirror of https://github.com/k3s-io/k3s
cluster: move logging library to hack/
it's used once in cluster and used a bunch in hack/ and build/pull/6/head
parent
32dc50476e
commit
1e2b644260
|
@ -20,7 +20,6 @@ filegroup(
|
|||
"//cluster/images/etcd/rollback:all-srcs",
|
||||
"//cluster/images/hyperkube:all-srcs",
|
||||
"//cluster/images/kubemark:all-srcs",
|
||||
"//cluster/lib:all-srcs",
|
||||
"//cluster/saltbase:all-srcs",
|
||||
],
|
||||
tags = ["automanaged"],
|
||||
|
@ -55,7 +54,6 @@ sh_test(
|
|||
name = "common_test",
|
||||
srcs = ["common.sh"],
|
||||
deps = [
|
||||
"//cluster/lib",
|
||||
"//hack/lib",
|
||||
],
|
||||
)
|
||||
|
@ -64,7 +62,6 @@ sh_test(
|
|||
name = "clientbin_test",
|
||||
srcs = ["clientbin.sh"],
|
||||
deps = [
|
||||
"//cluster/lib",
|
||||
"//hack/lib",
|
||||
],
|
||||
)
|
||||
|
@ -73,7 +70,6 @@ sh_test(
|
|||
name = "kube-util_test",
|
||||
srcs = ["kube-util.sh"],
|
||||
deps = [
|
||||
"//cluster/lib",
|
||||
"//hack/lib",
|
||||
],
|
||||
)
|
||||
|
|
|
@ -25,7 +25,6 @@ KUBE_ROOT=$(cd $(dirname "${BASH_SOURCE}")/.. && pwd)
|
|||
DEFAULT_KUBECONFIG="${HOME:-.}/.kube/config"
|
||||
|
||||
source "${KUBE_ROOT}/hack/lib/util.sh"
|
||||
source "${KUBE_ROOT}/cluster/lib/logging.sh"
|
||||
# KUBE_RELEASE_VERSION_REGEX matches things like "v1.2.3" or "v1.2.3-alpha.4"
|
||||
#
|
||||
# NOTE This must match the version_regex in build/common.sh
|
||||
|
@ -499,7 +498,7 @@ function stage-images() {
|
|||
done
|
||||
|
||||
kube::util::wait-for-jobs || {
|
||||
kube::log::error "unable to push images. See ${temp_dir}/*.log for more info."
|
||||
echo "!!! unable to push images. See ${temp_dir}/*.log for more info." 1>&2
|
||||
return 1
|
||||
}
|
||||
|
||||
|
|
|
@ -1,25 +0,0 @@
|
|||
sh_library(
|
||||
name = "lib",
|
||||
srcs = [
|
||||
"logging.sh",
|
||||
],
|
||||
visibility = [
|
||||
"//build/visible_to:COMMON_testing",
|
||||
"//build/visible_to:cluster",
|
||||
],
|
||||
)
|
||||
|
||||
filegroup(
|
||||
name = "package-srcs",
|
||||
srcs = glob(["**"]),
|
||||
tags = ["automanaged"],
|
||||
)
|
||||
|
||||
filegroup(
|
||||
name = "all-srcs",
|
||||
srcs = [":package-srcs"],
|
||||
tags = ["automanaged"],
|
||||
visibility = [
|
||||
"//build/visible_to:cluster",
|
||||
],
|
||||
)
|
|
@ -22,7 +22,7 @@ if [[ -z "${KUBE_ROOT:-}" ]]; then
|
|||
KUBE_ROOT=$(dirname "${BASH_SOURCE}")/..
|
||||
fi
|
||||
|
||||
source "${KUBE_ROOT}/cluster/lib/logging.sh"
|
||||
source "${KUBE_ROOT}/hack/lib/logging.sh"
|
||||
|
||||
if [[ ! -d "${KUBE_ROOT}/examples" ]]; then
|
||||
echo "${KUBE_ROOT}/examples not detected. This script should be run from a location where the source dirs are available."
|
||||
|
|
|
@ -6,14 +6,12 @@ sh_library(
|
|||
"etcd.sh",
|
||||
"golang.sh",
|
||||
"init.sh",
|
||||
"logging.sh",
|
||||
"swagger.sh",
|
||||
"test.sh",
|
||||
"util.sh",
|
||||
"version.sh",
|
||||
],
|
||||
deps = [
|
||||
"//cluster/lib",
|
||||
],
|
||||
)
|
||||
|
||||
filegroup(
|
||||
|
|
|
@ -37,7 +37,7 @@ export no_proxy=127.0.0.1,localhost
|
|||
THIS_PLATFORM_BIN="${KUBE_ROOT}/_output/bin"
|
||||
|
||||
source "${KUBE_ROOT}/hack/lib/util.sh"
|
||||
source "${KUBE_ROOT}/cluster/lib/logging.sh"
|
||||
source "${KUBE_ROOT}/hack/lib/logging.sh"
|
||||
|
||||
kube::log::install_errexit
|
||||
|
||||
|
|
|
@ -22,7 +22,7 @@ set -o errexit
|
|||
set -o nounset
|
||||
set -o pipefail
|
||||
|
||||
source cluster/lib/logging.sh
|
||||
source hack/lib/logging.sh
|
||||
|
||||
|
||||
if [[ $# -eq 0 || ! $1 =~ ^[Yy]$ ]]; then
|
||||
|
|
Loading…
Reference in New Issue