diff options
author | Justin chi <chigang@huawei.com> | 2017-10-16 01:46:57 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@opnfv.org> | 2017-10-16 01:46:57 +0000 |
commit | 45af5111e2c39105cdfd38a7ab8f3def25c3779d (patch) | |
tree | 8a2750d18690174100ff24697d39b05e2545ba01 /deploy/compass_conf | |
parent | b3aec6773447e8ab0b532723b08fd76ebddf9d8c (diff) | |
parent | 179cd6db9f1bd9be1606187cf74e128bede7a8e6 (diff) |
Merge "Modification for kargo to generate dynamic inventory"
Diffstat (limited to 'deploy/compass_conf')
-rwxr-xr-x[-rw-r--r--] | deploy/compass_conf/flavor/kubernetes.conf | 2 | ||||
-rwxr-xr-x[-rw-r--r--] | deploy/compass_conf/flavor_mapping/kubernetes.conf | 0 | ||||
-rwxr-xr-x[-rw-r--r--] | deploy/compass_conf/flavor_metadata/ansible-kubernetes.conf | 0 | ||||
-rwxr-xr-x[-rw-r--r--] | deploy/compass_conf/package_installer/ansible-kubernetes.conf | 2 | ||||
-rwxr-xr-x[-rw-r--r--] | deploy/compass_conf/role/kubernetes_ansible.conf | 126 | ||||
-rw-r--r-- | deploy/compass_conf/templates/ansible_installer/kubernetes/hosts/ansible-kubernetes.tmpl | 20 | ||||
-rw-r--r-- | deploy/compass_conf/templates/ansible_installer/kubernetes/vars/ansible-kubernetes.tmpl | 6 |
7 files changed, 28 insertions, 128 deletions
diff --git a/deploy/compass_conf/flavor/kubernetes.conf b/deploy/compass_conf/flavor/kubernetes.conf index 96b5f95f..35c43155 100644..100755 --- a/deploy/compass_conf/flavor/kubernetes.conf +++ b/deploy/compass_conf/flavor/kubernetes.conf @@ -4,7 +4,7 @@ FLAVORS = [{ 'display_name': 'ansible-kubernetes', 'template': 'ansible-kubernetes.tmpl', 'roles': [ - 'controller', 'compute', 'ha', 'odl', 'onos', 'opencontrail', 'ceph', 'ceph-adm', 'ceph-mon', 'ceph-osd', 'sec-patch', 'ceph-osd-node' + 'kube_master', 'etcd', 'kube_node' ], }] diff --git a/deploy/compass_conf/flavor_mapping/kubernetes.conf b/deploy/compass_conf/flavor_mapping/kubernetes.conf index e569ea46..e569ea46 100644..100755 --- a/deploy/compass_conf/flavor_mapping/kubernetes.conf +++ b/deploy/compass_conf/flavor_mapping/kubernetes.conf diff --git a/deploy/compass_conf/flavor_metadata/ansible-kubernetes.conf b/deploy/compass_conf/flavor_metadata/ansible-kubernetes.conf index f878d58c..f878d58c 100644..100755 --- a/deploy/compass_conf/flavor_metadata/ansible-kubernetes.conf +++ b/deploy/compass_conf/flavor_metadata/ansible-kubernetes.conf diff --git a/deploy/compass_conf/package_installer/ansible-kubernetes.conf b/deploy/compass_conf/package_installer/ansible-kubernetes.conf index c706ccb2..32590c82 100644..100755 --- a/deploy/compass_conf/package_installer/ansible-kubernetes.conf +++ b/deploy/compass_conf/package_installer/ansible-kubernetes.conf @@ -7,7 +7,7 @@ SETTINGS = { 'playbook_file': 'site.yml', 'inventory_file': 'inventory.py', 'inventory_json_file': 'inventory.json', - 'inventory_group': ['controller', 'compute', 'ha', 'odl', 'onos', 'opencontrail', 'ceph_adm', 'ceph_mon', 'ceph_osd', 'moon'], + 'inventory_group': ['kube_master', 'etcd', 'kube_node'], 'group_variable': 'all', 'etc_hosts_path': 'roles/pre-k8s/templates/hosts', 'runner_dirs': ['roles','kubernetes/roles'] diff --git a/deploy/compass_conf/role/kubernetes_ansible.conf b/deploy/compass_conf/role/kubernetes_ansible.conf index 89c03d94..ae096f47 100644..100755 --- a/deploy/compass_conf/role/kubernetes_ansible.conf +++ b/deploy/compass_conf/role/kubernetes_ansible.conf @@ -1,115 +1,15 @@ ADAPTER_NAME = 'kubernetes' ROLES = [{ - 'role': 'allinone-compute', - 'display_name': 'all in one', - 'description': 'All in One' -}, { - 'role': 'controller', - 'display_name': 'controller node', - 'description': 'Controller Node' -}, { - 'role': 'compute', - 'display_name': 'compute node', - 'description': 'Compute Node' -}, { - 'role': 'storage', - 'display_name': 'storage node', - 'description': 'Storage Node' -}, { - 'role': 'network', - 'display_name': 'network node', - 'description': 'Network Node' -}, { - 'role': 'compute-worker', - 'display_name': 'Compute worker node', - 'description': 'Compute worker node' -}, { - 'role': 'compute-controller', - 'display_name': 'Compute controller node', - 'description': 'Compute controller node' -}, { - 'role': 'network-server', - 'display_name': 'Network server node', - 'description': 'Network server node' -}, { - 'role': 'database', - 'display_name': 'Database node', - 'description': 'Database node' -}, { - 'role': 'messaging', - 'display_name': 'Messaging queue node', - 'description': 'Messaging queue node' -}, { - 'role': 'image', - 'display': 'Image node', - 'description': 'Image node' -}, { - 'role': 'dashboard', - 'display': 'Dashboard node', - 'description': 'Dashboard node' -}, { - 'role': 'identity', - 'display': 'Identity node', - 'description': 'Identity node' -}, { - 'role': 'storage-controller', - 'display': 'Storage controller node', - 'description': 'Storage controller node' -}, { - 'role': 'storage-volume', - 'display': 'Storage volume node', - 'description': 'Storage volume node' -}, { - 'role': 'network-worker', - 'display': 'Network worker node', - 'description': 'Network worker node' -}, { - 'role': 'odl', - 'display': 'open day light', - 'description': 'odl node', - 'optional': True -}, { - 'role': 'onos', - 'display': 'open network operating system', - 'description': 'onos node', - 'optional': True -}, { - 'role': 'opencontrail', - 'display': 'open contrail', - 'description': 'opencontrail node', - 'optional': True -}, { - 'role': 'ha', - 'display': 'Cluster with HA', - 'description': 'Cluster with HA node' -}, { - 'role': 'ceph-adm', - 'display': 'Ceph Admin Node', - 'description': 'Ceph Admin Node', - 'optional': True -}, { - 'role': 'ceph-mon', - 'display': 'Ceph Monitor Node', - 'description': 'Ceph Monitor Node', - 'optional': True -}, { - 'role': 'ceph-osd', - 'display': 'Ceph Storage Node', - 'description': 'Ceph Storage Node', - 'optional': True -}, { - 'role': 'ceph-osd-node', - 'display': 'Ceph osd install from node', - 'description': '', - 'optional': True -}, { - 'role': 'ceph', - 'display': 'ceph node', - 'description': 'ceph node', - 'optional': True -}, { - 'role': 'sec-patch', - 'display': 'sec-patch node', - 'description': 'Security Patch Node', - 'optional': True -}] + 'role': 'kube_master', + 'display_name': 'kubnernets master node', + 'description': ' include kube-api,kube-scheduler' +}, { + 'role': 'etcd', + 'display_name': 'etcd node', + 'description': 'etcd Node' +}, { + 'role': 'kube_node', + 'display_name': 'kube node', + 'description': 'kube Node' +} +] diff --git a/deploy/compass_conf/templates/ansible_installer/kubernetes/hosts/ansible-kubernetes.tmpl b/deploy/compass_conf/templates/ansible_installer/kubernetes/hosts/ansible-kubernetes.tmpl index 9d628b5e..0a9e3025 100644 --- a/deploy/compass_conf/templates/ansible_installer/kubernetes/hosts/ansible-kubernetes.tmpl +++ b/deploy/compass_conf/templates/ansible_installer/kubernetes/hosts/ansible-kubernetes.tmpl @@ -9,22 +9,22 @@ # localhost 127.0.0.1 localhost -#set controllers = $getVar('controller', []) -#set computes = $getVar('compute', []) -#if not $isinstance($controllers, list) - #set controllers = [$controllers] +#set kube_masters = $getVar('kube_master', []) +#set kube_nodes = $getVar('kube_node', []) +#if not $isinstance($kube_masters, list) + #set kube_masters = [$kube_masters] #end if -#if not $isinstance($compute, list) - #set computes = [$computes] +#if not $isinstance($kube_nodes, list) + #set kube_nodes = [$kube_nodes] #end if -# controller -#for worker in $controllers +# kube_master +#for worker in $kube_masters #set worker_hostname = $worker.hostname #set worker_ip = $ip_settings[$worker_hostname].mgmt.ip $worker_ip $worker_hostname #end for -# compute -#for worker in $computes +# kube_node +#for worker in $kube_nodes #set worker_hostname = $worker.hostname #set worker_ip = $ip_settings[$worker_hostname].mgmt.ip $worker_ip $worker_hostname diff --git a/deploy/compass_conf/templates/ansible_installer/kubernetes/vars/ansible-kubernetes.tmpl b/deploy/compass_conf/templates/ansible_installer/kubernetes/vars/ansible-kubernetes.tmpl index 27211e06..440bf7d7 100644 --- a/deploy/compass_conf/templates/ansible_installer/kubernetes/vars/ansible-kubernetes.tmpl +++ b/deploy/compass_conf/templates/ansible_installer/kubernetes/vars/ansible-kubernetes.tmpl @@ -20,8 +20,8 @@ #set has = $getVar('ha', []) #set ha_vip = $getVar('ha_vip', []) -#set controllers = $getVar('controller', []) -#set computers = $getVar('compute', []) +#set kube_masters = $getVar('kube_master', []) +#set kube_nodes = $getVar('kube_node', []) enable_secgroup: $getVar('enable_secgroup', True) enable_fwaas: $getVar('enable_fwaas', True) @@ -35,7 +35,7 @@ network_cfg: $network_cfg sys_intf_mappings: $sys_intf_mappings deploy_type: $getVar('deploy_type', 'virtual') -public_cidr: $computers[0]['install']['subnet'] +public_cidr: $kube_nodes[0]['install']['subnet'] storage_cidr: "{{ ip_settings[inventory_hostname]['storage']['cidr'] }}" mgmt_cidr: "{{ ip_settings[inventory_hostname]['mgmt']['cidr'] }}" |