mirror of https://github.com/k3s-io/k3s
Fix run-in-gopath issue with symlink'd gopath
parent
67e7d4c68f
commit
2edd10709c
|
@ -178,4 +178,3 @@ kube::realpath() {
|
|||
fi
|
||||
kube::readlinkdashf "$1"
|
||||
}
|
||||
|
||||
|
|
|
@ -20,8 +20,6 @@ set -o pipefail
|
|||
export KUBE_ROOT=$(dirname "${BASH_SOURCE}")/..
|
||||
source "${KUBE_ROOT}/hack/lib/init.sh"
|
||||
|
||||
kube::util::ensure-gnu-sed
|
||||
|
||||
# Remove generated files prior to running kazel.
|
||||
# TODO(spxtr): Remove this line once Bazel is the only way to build.
|
||||
rm -f "${KUBE_ROOT}/pkg/generated/openapi/zz_generated.openapi.go"
|
||||
|
@ -31,9 +29,8 @@ export GOBIN="${KUBE_OUTPUT_BINPATH}"
|
|||
PATH="${GOBIN}:${PATH}"
|
||||
|
||||
# Install tools we need, but only from vendor/...
|
||||
go install ./vendor/github.com/bazelbuild/bazel-gazelle/cmd/gazelle
|
||||
|
||||
go install ./vendor/github.com/kubernetes/repo-infra/kazel
|
||||
go install k8s.io/kubernetes/vendor/github.com/bazelbuild/bazel-gazelle/cmd/gazelle
|
||||
go install k8s.io/kubernetes/vendor/github.com/kubernetes/repo-infra/kazel
|
||||
|
||||
touch "${KUBE_ROOT}/vendor/BUILD"
|
||||
# Ensure that we use the correct importmap for all vendored dependencies.
|
||||
|
@ -46,6 +43,8 @@ fi
|
|||
gazelle fix \
|
||||
-build_file_name=BUILD,BUILD.bazel \
|
||||
-external=vendored \
|
||||
-mode=fix
|
||||
-mode=fix \
|
||||
-repo_root "${KUBE_ROOT}" \
|
||||
"${KUBE_ROOT}"
|
||||
|
||||
kazel
|
||||
|
|
Loading…
Reference in New Issue