mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-23 11:50:44 +00:00
When installing vendored godep, ensure that it's in path
This commit is contained in:
parent
78ed389122
commit
d58afe6384
@ -446,6 +446,9 @@ kube::util::ensure_godep_version() {
|
||||
|
||||
kube::log::status "Installing godep version ${GODEP_VERSION}"
|
||||
go install ./vendor/github.com/tools/godep/
|
||||
GP="$(echo $GOPATH | cut -f1 -d:)"
|
||||
hash -r # force bash to clear PATH cache
|
||||
PATH="${GP}/bin:${PATH}"
|
||||
|
||||
if [[ "$(godep version 2>/dev/null)" != *"godep ${GODEP_VERSION}"* ]]; then
|
||||
kube::log::error "Expected godep ${GODEP_VERSION}, got $(godep version)"
|
||||
|
@ -29,6 +29,9 @@ if ! [[ ${KUBE_FORCE_VERIFY_CHECKS:-} =~ ^[yY]$ ]] && \
|
||||
exit 0
|
||||
fi
|
||||
|
||||
# Ensure we have the right godep version available
|
||||
kube::util::ensure_godep_version
|
||||
|
||||
if [[ -z ${TMP_GOPATH:-} ]]; then
|
||||
# Create a nice clean place to put our new godeps
|
||||
_tmpdir="$(mktemp -d -t gopath.XXXXXX)"
|
||||
|
Loading…
Reference in New Issue
Block a user