From d9455735497977e35835b654b6b9a8b299f88ceb Mon Sep 17 00:00:00 2001 From: Roman Mohr Date: Fri, 13 Apr 2018 12:51:47 +0200 Subject: [PATCH] Rename VAGRANT_NUM_NODES to KUBEVIRT_NUM_NODES Signed-off-by: Roman Mohr --- Vagrantfile | 2 +- automation/check-patch.sh | 2 +- automation/test.sh | 2 +- cluster/ephemeral-provider-common.sh | 4 ++-- cluster/k8s-1.9.3/README.md | 2 +- cluster/os-3.9.0/README.md | 4 ++-- cluster/vagrant-kubernetes/README.md | 2 +- cluster/vagrant-openshift/README.md | 2 +- docs/env-providers.md | 2 +- docs/getting-started.md | 4 ++-- 10 files changed, 13 insertions(+), 13 deletions(-) diff --git a/Vagrantfile b/Vagrantfile index a0d1f8f9b384..0e92861b1b9e 100644 --- a/Vagrantfile +++ b/Vagrantfile @@ -15,7 +15,7 @@ $use_nfs = ENV['VAGRANT_USE_NFS'] == 'true' $use_rng = ENV['VAGRANT_USE_RNG'] == 'true' $cache_docker = ENV['VAGRANT_CACHE_DOCKER'] == 'true' $cache_rpm = ENV['VAGRANT_CACHE_RPM'] == 'true' -$nodes = (ENV['VAGRANT_NUM_NODES'] || 0).to_i +$nodes = (ENV['KUBEVIRT_NUM_NODES'] || 0).to_i $vagrant_pool = (ENV['VAGRANT_POOL'] unless (ENV['VAGRANT_POOL'].nil? or ENV['VAGRANT_POOL'].empty?)) # Used for matrix builds to similar setups on the same node without vagrant diff --git a/automation/check-patch.sh b/automation/check-patch.sh index 238b368e34ad..94bb6943c8ea 100755 --- a/automation/check-patch.sh +++ b/automation/check-patch.sh @@ -64,7 +64,7 @@ setup_vagrant_env() { export VAGRANT_USE_NFS=false export VAGRANT_CACHE_RPM=true export VAGRANT_CACHE_DOCKER=true - export VAGRANT_NUM_NODES=1 + export KUBEVIRT_NUM_NODES=1 } setup_go_dirs() { diff --git a/automation/test.sh b/automation/test.sh index 9dd785a66145..7f5e58313531 100755 --- a/automation/test.sh +++ b/automation/test.sh @@ -40,7 +40,7 @@ else export PROVIDER="k8s-1.9.3" fi -export VAGRANT_NUM_NODES=1 +export KUBEVIRT_NUM_NODES=1 export NFS_WINDOWS_DIR=${NFS_WINDOWS_DIR:-/home/nfs/images/windows2016} kubectl() { cluster/kubectl.sh "$@"; } diff --git a/cluster/ephemeral-provider-common.sh b/cluster/ephemeral-provider-common.sh index 6343f566ac5c..9ad8b2526277 100644 --- a/cluster/ephemeral-provider-common.sh +++ b/cluster/ephemeral-provider-common.sh @@ -30,7 +30,7 @@ function _registry_volume() { function _add_common_params() { # Add one, 0 here means no node at all, but in the kubevirt repo it means master-only - local num_nodes=${VAGRANT_NUM_NODES-0} + local num_nodes=${KUBEVIRT_NUM_NODES-0} num_nodes=$((num_nodes + 1)) local params="--nodes ${num_nodes} --random-ports --background --prefix $provider_prefix --registry-volume $(_registry_volume) --base "kubevirtci/${image}"" if [ -d "$NFS_WINDOWS_DIR" ]; then @@ -61,7 +61,7 @@ function build() { container="${container} ${manifest_docker_prefix}/${name}:${docker_tag}" container_alias="${container_alias} ${manifest_docker_prefix}/${name}:${docker_tag} kubevirt/${name}:${docker_tag}" done - local num_nodes=${VAGRANT_NUM_NODES-0} + local num_nodes=${KUBEVIRT_NUM_NODES-0} num_nodes=$((num_nodes + 1)) for i in $(seq 1 ${num_nodes}); do ${_cli} ssh --prefix $provider_prefix "node$(printf "%02d" ${i})" "echo \"${container}\" | xargs --max-args=1 sudo docker pull" diff --git a/cluster/k8s-1.9.3/README.md b/cluster/k8s-1.9.3/README.md index f135c75608ce..e0995eafa4d4 100644 --- a/cluster/k8s-1.9.3/README.md +++ b/cluster/k8s-1.9.3/README.md @@ -10,7 +10,7 @@ local machine and are the pushed to a registry which is exposed at ```bash export PROVIDER=k8s-1.9.3 -export VAGRANT_NUM_NODES=1 # master + one nodes +export KUBEVIRT_NUM_NODES=1 # master + one nodes make cluster-up ``` diff --git a/cluster/os-3.9.0/README.md b/cluster/os-3.9.0/README.md index 430a7116c0ac..fac9bcc9a254 100644 --- a/cluster/os-3.9.0/README.md +++ b/cluster/os-3.9.0/README.md @@ -10,7 +10,7 @@ local machine and are the pushed to a registry which is exposed at ```bash export PROVIDER=os-3.9.0 -export VAGRANT_NUM_NODES=1 # master + one nodes +export KUBEVIRT_NUM_NODES=1 # master + one nodes make cluster-up ``` @@ -31,7 +31,7 @@ node02 Ready 46s v1.9.1+a0ce1bc657 ## Bringing the cluster down ```bash -export PROVIDER=os-3.9.0 +export KUBEVIRT_PROVIDER=os-3.9.0 make cluster-down ``` diff --git a/cluster/vagrant-kubernetes/README.md b/cluster/vagrant-kubernetes/README.md index 756336419b36..8b27f3025b5d 100644 --- a/cluster/vagrant-kubernetes/README.md +++ b/cluster/vagrant-kubernetes/README.md @@ -7,7 +7,7 @@ It will deploy k8s only first time when you start a VM. ```bash export PROVIDER=vagrant-kubernetes -export VAGRANT_NUM_NODES=1 +export KUBEVIRT_NUM_NODES=1 make cluster-up ``` diff --git a/cluster/vagrant-openshift/README.md b/cluster/vagrant-openshift/README.md index 2ec7a0996ca0..a42c8dea5ac1 100644 --- a/cluster/vagrant-openshift/README.md +++ b/cluster/vagrant-openshift/README.md @@ -7,7 +7,7 @@ It will deploy OpenShift only first time when you start a VM. ```bash export PROVIDER=vagrant-openshift -export VAGRANT_NUM_NODES=1 +export KUBEVIRT_NUM_NODES=1 make cluster-up ``` diff --git a/docs/env-providers.md b/docs/env-providers.md index a464c9154b2f..2887ebf3334a 100644 --- a/docs/env-providers.md +++ b/docs/env-providers.md @@ -26,7 +26,7 @@ Usage: ```bash export PROVIDER=vagrant-kubernetes # choose this provider -export VAGRANT_NUM_NODES=2 # master + two nodes +export KUBEVIRT_NUM_NODES=2 # master + two nodes make cluster-up ``` diff --git a/docs/getting-started.md b/docs/getting-started.md index 5cb2cfb5a7cc..193b4426fa1c 100644 --- a/docs/getting-started.md +++ b/docs/getting-started.md @@ -26,11 +26,11 @@ dockerizied environment: This will create a VM called `node01` which acts as Kubernetes master and then deploy KubeVirt there. To create one or more nodes which will register -themselves on master, you can use the `VAGRANT_NUM_NODES` environment variable. +themselves on master, you can use the `KUBEVIRT_NUM_NODES` environment variable. This would create a master and one node: ```bash - export VAGRANT_NUM_NODES=1 + export KUBEVIRT_NUM_NODES=1 make cluster-up ```