Fix helm command not found issue when kubeconfig is not provided.
This commit is contained in:
+1
-1
@@ -9,7 +9,7 @@ branches:
|
||||
language: go
|
||||
|
||||
go:
|
||||
- 1.10.2
|
||||
- 1.11.x
|
||||
|
||||
cache:
|
||||
directories:
|
||||
|
||||
+15
-15
@@ -6,13 +6,6 @@
|
||||
|
||||
set -e
|
||||
|
||||
# If we don't have gcloud credentials, bail out of these tests.
|
||||
if [ -z "$FISSION_CI_SERVICE_ACCOUNT" ]
|
||||
then
|
||||
echo "Skipping tests, no cluster credentials"
|
||||
exit 0
|
||||
fi
|
||||
|
||||
K8SCLI_DIR=$HOME/k8scli
|
||||
|
||||
if [ ! -d $K8SCLI_DIR ]
|
||||
@@ -20,14 +13,6 @@ then
|
||||
mkdir -p $K8SCLI_DIR
|
||||
fi
|
||||
|
||||
# Get kubectl
|
||||
if [ ! -f $K8SCLI_DIR/kubectl ]
|
||||
then
|
||||
curl -LO https://storage.googleapis.com/kubernetes-release/release/$(curl -s https://storage.googleapis.com/kubernetes-release/release/stable.txt)/bin/linux/amd64/kubectl
|
||||
chmod +x ./kubectl
|
||||
mv kubectl $K8SCLI_DIR/kubectl
|
||||
fi
|
||||
|
||||
# Get helm
|
||||
if [ ! -f $K8SCLI_DIR/helm ]
|
||||
then
|
||||
@@ -36,6 +21,21 @@ then
|
||||
mv linux-amd64/helm $K8SCLI_DIR/helm
|
||||
fi
|
||||
|
||||
# If we don't have gcloud credentials, bail out of these tests.
|
||||
if [ -z "$FISSION_CI_SERVICE_ACCOUNT" ]
|
||||
then
|
||||
echo "Skipping tests, no cluster credentials"
|
||||
exit 0
|
||||
fi
|
||||
|
||||
# Get kubectl
|
||||
if [ ! -f $K8SCLI_DIR/kubectl ]
|
||||
then
|
||||
curl -LO https://storage.googleapis.com/kubernetes-release/release/$(curl -s https://storage.googleapis.com/kubernetes-release/release/stable.txt)/bin/linux/amd64/kubectl
|
||||
chmod +x ./kubectl
|
||||
mv kubectl $K8SCLI_DIR/kubectl
|
||||
fi
|
||||
|
||||
mkdir ${HOME}/.kube
|
||||
|
||||
# echo $KUBECONFIG_CONTENTS | base64 -D - > ${HOME}/.kube/config
|
||||
|
||||
@@ -237,7 +237,7 @@ func (roundTripper RetryingRoundTripper) RoundTrip(req *http.Request) (resp *htt
|
||||
time.Now().UnixNano(),
|
||||
)
|
||||
} else {
|
||||
log.Println("No http trigger attached for recorder: %v", roundTripper.funcHandler.recorderName)
|
||||
log.Printf("No http trigger attached for recorder: %v", roundTripper.funcHandler.recorderName)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user