Skip to content

Commit

Permalink
contrib/vagrant: Fix warning when K8S is unset
Browse files Browse the repository at this point in the history
Pull request #10049 changed the way K8S is checked in the start.sh
script to try and enable the "K8S=0" syntax to disable the Kubernetes
build.  This change results in the following warning when K8S is unset:

  ./contrib/vagrant/start.sh: line 607: [: : integer expression expected

This commit reverts that specific change.  K8S should be 1 or unset to
enable or disable the Kubernetes build respectively.

Signed-off-by: Paul Chaignon <paul@cilium.io>
  • Loading branch information
pchaigno authored and aanm committed Feb 21, 2020
1 parent ff8e615 commit 9a069f9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion contrib/vagrant/start.sh
Expand Up @@ -601,7 +601,7 @@ elif [ -n "${PROVISION}" ]; then
vagrant provision
else
vagrant up
if [ "$?" -eq "0" -a "${K8S}" -eq "1" ]; then
if [ "$?" -eq "0" -a -n "${K8S}" ]; then
vagrant ssh k8s1 -- cat /home/vagrant/.kube/config | sed 's;server:.*:6443;server: https://k8s1:7443;g' > vagrant.kubeconfig
echo "Add '127.0.0.1 k8s1' to your /etc/hosts to use vagrant.kubeconfig file for kubectl"
fi
Expand Down

0 comments on commit 9a069f9

Please sign in to comment.