Add NUMBER_OF_MONITOR_NODES for bootstrap

The parameter "NUMBER_OF_MONITOR_NODES" is needed when run
bootstrap.sh[0], but it's missing, this ps to add it.

[0]: https://github.com/openstack/kolla-ansible/blob/master/contrib/dev/vagrant/bootstrap.sh#L206

Change-Id: If83620bbdeaf8c4805e021242ca44da069e43922
This commit is contained in:
ZhijunWei 2018-06-15 03:16:35 +00:00 committed by zhulingjie
parent b76f40166a
commit 5f19844c29
3 changed files with 13 additions and 2 deletions

View File

@ -85,6 +85,7 @@ NUMBER_OF_CONTROL_NODES ||= 3
NUMBER_OF_COMPUTE_NODES ||= 1 NUMBER_OF_COMPUTE_NODES ||= 1
NUMBER_OF_STORAGE_NODES ||= 1 NUMBER_OF_STORAGE_NODES ||= 1
NUMBER_OF_NETWORK_NODES ||= 1 NUMBER_OF_NETWORK_NODES ||= 1
NUMBER_OF_MONITOR_NODES ||= 1
NODE_SETTINGS ||= { NODE_SETTINGS ||= {
aio: { aio: {
@ -110,6 +111,10 @@ NODE_SETTINGS ||= {
network: { network: {
cpus: 1, cpus: 1,
memory: 1024 memory: 1024
},
monitor: {
cpus: 1,
memory: 1024
} }
} }
@ -232,7 +237,7 @@ Vagrant.configure(2) do |config|
# The operator controls the deployment # The operator controls the deployment
config.vm.define "operator", primary: true do |admin| config.vm.define "operator", primary: true do |admin|
admin.vm.hostname = "operator.local" admin.vm.hostname = "operator.local"
admin.vm.provision :shell, path: PROVISION_SCRIPT, args: "operator #{MULTINODE ? 'multinode' : 'aio'} #{kolla_path} #{kolla_ansible_path} #{kolla_cli_path} #{NUMBER_OF_COMPUTE_NODES} #{NUMBER_OF_STORAGE_NODES} #{NUMBER_OF_NETWORK_NODES} #{NUMBER_OF_CONTROL_NODES}" admin.vm.provision :shell, path: PROVISION_SCRIPT, args: "operator #{MULTINODE ? 'multinode' : 'aio'} #{kolla_path} #{kolla_ansible_path} #{kolla_cli_path} #{NUMBER_OF_COMPUTE_NODES} #{NUMBER_OF_STORAGE_NODES} #{NUMBER_OF_NETWORK_NODES} #{NUMBER_OF_CONTROL_NODES} #{NUMBER_OF_MONITOR_NODES}"
admin.vm.synced_folder kolla_ansible_repo_path, kolla_ansible_path, create:"True", type: get_default(:sync_method) admin.vm.synced_folder kolla_ansible_repo_path, kolla_ansible_path, create:"True", type: get_default(:sync_method)
admin.vm.synced_folder kolla_repo_path, kolla_path, create:"True", type: get_default(:sync_method) admin.vm.synced_folder kolla_repo_path, kolla_path, create:"True", type: get_default(:sync_method)
admin.vm.synced_folder kolla_cli_repo_path, kolla_cli_path, create:"True", type: get_default(:sync_method) admin.vm.synced_folder kolla_cli_repo_path, kolla_cli_path, create:"True", type: get_default(:sync_method)
@ -256,7 +261,7 @@ Vagrant.configure(2) do |config|
hostname = "#{node_type}0#{i}" hostname = "#{node_type}0#{i}"
config.vm.define hostname do |node| config.vm.define hostname do |node|
node.vm.hostname = "#{hostname}.local" node.vm.hostname = "#{hostname}.local"
node.vm.provision :shell, path: PROVISION_SCRIPT, args: "#{hostname} multinode #{kolla_path} #{kolla_ansible_path} #{kolla_cli_path} #{NUMBER_OF_COMPUTE_NODES} #{NUMBER_OF_STORAGE_NODES} #{NUMBER_OF_NETWORK_NODES} #{NUMBER_OF_CONTROL_NODES}" node.vm.provision :shell, path: PROVISION_SCRIPT, args: "#{hostname} multinode #{kolla_path} #{kolla_ansible_path} #{kolla_cli_path} #{NUMBER_OF_COMPUTE_NODES} #{NUMBER_OF_STORAGE_NODES} #{NUMBER_OF_NETWORK_NODES} #{NUMBER_OF_CONTROL_NODES} #{NUMBER_OF_MONITOR_NODES}"
node.vm.synced_folder File.join(vagrant_dir, 'storage', node_type), "/data/host", create:"True", type: get_default(:sync_method) node.vm.synced_folder File.join(vagrant_dir, 'storage', node_type), "/data/host", create:"True", type: get_default(:sync_method)
node.vm.synced_folder File.join(vagrant_dir, 'storage', 'shared'), "/data/shared", create:"True", type: get_default(:sync_method) node.vm.synced_folder File.join(vagrant_dir, 'storage', 'shared'), "/data/shared", create:"True", type: get_default(:sync_method)
node.vm.synced_folder ".", vagrant_shared_folder, disabled: true node.vm.synced_folder ".", vagrant_shared_folder, disabled: true

View File

@ -68,6 +68,7 @@
# NUMBER_OF_COMPUTE_NODES = 1 # NUMBER_OF_COMPUTE_NODES = 1
# NUMBER_OF_STORAGE_NODES = 1 # NUMBER_OF_STORAGE_NODES = 1
# NUMBER_OF_NETWORK_NODES = 1 # NUMBER_OF_NETWORK_NODES = 1
# NUMBER_OF_MONITOR_NODES = 1
# NODE_SETTINGS = { # NODE_SETTINGS = {
# aio: { # aio: {
@ -93,5 +94,9 @@
# network: { # network: {
# cpus: 1, # cpus: 1,
# memory: 1024 # memory: 1024
# },
# monitor: {
# cpus: 1,
# memory: 1024
# } # }
# } # }

View File

@ -15,6 +15,7 @@ NUMBER_OF_COMPUTE_NODES=$6
NUMBER_OF_STORAGE_NODES=$7 NUMBER_OF_STORAGE_NODES=$7
NUMBER_OF_NETWORK_NODES=$8 NUMBER_OF_NETWORK_NODES=$8
NUMBER_OF_CONTROL_NODES=$9 NUMBER_OF_CONTROL_NODES=$9
NUMBER_OF_MONITOR_NODES=$10
export http_proxy= export http_proxy=
export https_proxy= export https_proxy=