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