From 5cc5559348a8a18a41cfd25cce446955d63afb83 Mon Sep 17 00:00:00 2001 From: David Blaisonneau Date: Thu, 4 Aug 2016 17:37:15 +0200 Subject: New scripts for configs generation, based on jinja2 Signed-off-by: David Blaisonneau --- ci/config_tpl/bundle_tpl/aodh.yaml | 5 ++ ci/config_tpl/bundle_tpl/bundle.yaml | 60 ++++++++++++++ ci/config_tpl/bundle_tpl/ceilometer.yaml | 18 ++++ ci/config_tpl/bundle_tpl/ceph.yaml | 36 ++++++++ ci/config_tpl/bundle_tpl/cinder.yaml | 16 ++++ ci/config_tpl/bundle_tpl/congress.yaml | 9 ++ ci/config_tpl/bundle_tpl/glance.yaml | 14 ++++ ci/config_tpl/bundle_tpl/haclusters.yaml | 53 ++++++++++++ ci/config_tpl/bundle_tpl/harelations.yaml | 14 ++++ ci/config_tpl/bundle_tpl/heat.yaml | 13 +++ ci/config_tpl/bundle_tpl/keystone.yaml | 16 ++++ ci/config_tpl/bundle_tpl/mysql.yaml | 17 ++++ ci/config_tpl/bundle_tpl/neutron-api.yaml | 26 ++++++ ci/config_tpl/bundle_tpl/neutron-gateway.yaml | 46 +++++++++++ ci/config_tpl/bundle_tpl/neutron-ovs.yaml | 31 +++++++ .../bundle_tpl/nova-cloud-controller.yaml | 21 +++++ ci/config_tpl/bundle_tpl/nova-compute.yaml | 18 ++++ ci/config_tpl/bundle_tpl/oclphase1.yaml | 58 +++++++++++++ ci/config_tpl/bundle_tpl/odl.yaml | 17 ++++ ci/config_tpl/bundle_tpl/onos.yaml | 9 ++ ci/config_tpl/bundle_tpl/openstack-dashboard.yaml | 16 ++++ ci/config_tpl/bundle_tpl/opnfv-promise.yaml | 5 ++ ci/config_tpl/bundle_tpl/phase2-overrides.yaml | 25 ++++++ ci/config_tpl/bundle_tpl/rabbitmq.yaml | 12 +++ ci/config_tpl/bundle_tpl/relations.yaml | 95 ++++++++++++++++++++++ ci/config_tpl/bundle_tpl/subordinate.yaml | 55 +++++++++++++ 26 files changed, 705 insertions(+) create mode 100644 ci/config_tpl/bundle_tpl/aodh.yaml create mode 100644 ci/config_tpl/bundle_tpl/bundle.yaml create mode 100644 ci/config_tpl/bundle_tpl/ceilometer.yaml create mode 100644 ci/config_tpl/bundle_tpl/ceph.yaml create mode 100644 ci/config_tpl/bundle_tpl/cinder.yaml create mode 100644 ci/config_tpl/bundle_tpl/congress.yaml create mode 100644 ci/config_tpl/bundle_tpl/glance.yaml create mode 100644 ci/config_tpl/bundle_tpl/haclusters.yaml create mode 100644 ci/config_tpl/bundle_tpl/harelations.yaml create mode 100644 ci/config_tpl/bundle_tpl/heat.yaml create mode 100644 ci/config_tpl/bundle_tpl/keystone.yaml create mode 100644 ci/config_tpl/bundle_tpl/mysql.yaml create mode 100644 ci/config_tpl/bundle_tpl/neutron-api.yaml create mode 100644 ci/config_tpl/bundle_tpl/neutron-gateway.yaml create mode 100644 ci/config_tpl/bundle_tpl/neutron-ovs.yaml create mode 100644 ci/config_tpl/bundle_tpl/nova-cloud-controller.yaml create mode 100644 ci/config_tpl/bundle_tpl/nova-compute.yaml create mode 100644 ci/config_tpl/bundle_tpl/oclphase1.yaml create mode 100644 ci/config_tpl/bundle_tpl/odl.yaml create mode 100644 ci/config_tpl/bundle_tpl/onos.yaml create mode 100644 ci/config_tpl/bundle_tpl/openstack-dashboard.yaml create mode 100644 ci/config_tpl/bundle_tpl/opnfv-promise.yaml create mode 100644 ci/config_tpl/bundle_tpl/phase2-overrides.yaml create mode 100644 ci/config_tpl/bundle_tpl/rabbitmq.yaml create mode 100644 ci/config_tpl/bundle_tpl/relations.yaml create mode 100644 ci/config_tpl/bundle_tpl/subordinate.yaml (limited to 'ci/config_tpl/bundle_tpl') diff --git a/ci/config_tpl/bundle_tpl/aodh.yaml b/ci/config_tpl/bundle_tpl/aodh.yaml new file mode 100644 index 00000000..271d3819 --- /dev/null +++ b/ci/config_tpl/bundle_tpl/aodh.yaml @@ -0,0 +1,5 @@ + aodh: + charm: "local:{{ ubuntu.release }}/aodh" + to: + - "lxc:nodes=0" +{# Empty block to avoid bad block trim #} diff --git a/ci/config_tpl/bundle_tpl/bundle.yaml b/ci/config_tpl/bundle_tpl/bundle.yaml new file mode 100644 index 00000000..8c08c1a2 --- /dev/null +++ b/ci/config_tpl/bundle_tpl/bundle.yaml @@ -0,0 +1,60 @@ +# vim: set ts=2 et: +{{ ubuntu.release }}-{{ os.release }}-nodes: + inherits: openstack-phase1 + overrides: +{% include 'phase2-overrides.yaml' %} + +{{ ubuntu.release }}-{{ os.release }}: + inherits: openstack-phase2 + +openstack-phase1: + services: + nodes: + charm: "cs:{{ ubuntu.release }}/ubuntu" + num_units: {{ opnfv.units }} + ntp: + charm: "local:{{ ubuntu.release }}/ntp" +{% if os.network.controller == 'ocl' %} + options: + source: "0.ubuntu.pool.ntp.org 1.ubuntu.pool.ntp.org 2.ubuntu.pool.ntp.org 3.ubuntu.pool.ntp.org" + auto_peers: false +{% endif %} +{% include 'mysql.yaml' %} +{% include 'ceilometer.yaml' %} +{% include 'ceph.yaml' %} +{% include 'cinder.yaml' %} +{% include 'glance.yaml' %} +{% include 'opnfv-promise.yaml' %} +{% include 'congress.yaml' %} +{% include 'keystone.yaml' %} +{% include 'nova-cloud-controller.yaml' %} +{% include 'nova-compute.yaml' %} +{% include 'openstack-dashboard.yaml' %} +{% include 'rabbitmq.yaml' %} +{% include 'heat.yaml' %} +{% include 'neutron-api.yaml' %} +{% include 'neutron-gateway.yaml' %} +{% include 'aodh.yaml' %} +{% if os.network.controller == 'odl' %} +{% include 'odl.yaml' %} +{% elif os.network.controller == 'onos' %} +{% include 'onos.yaml' %} +{% elif os.network.controller == 'ocl' %} +{% include 'oclphase1.yaml' %} +{% endif %} +{% if os.ha.mode == 'ha' %} +{% include 'haclusters.yaml' %} +{% endif %} + + relations: + - [ 'ntp:juju-info', 'nodes:juju-info' ] +{% if os.ha.mode == 'ha' %} +{% include 'harelations.yaml' %} +{% endif %} + +openstack-phase2: + inherits: openstack-phase1 + relations: +{% include 'relations.yaml' %} + services: +{% include 'subordinate.yaml' %} diff --git a/ci/config_tpl/bundle_tpl/ceilometer.yaml b/ci/config_tpl/bundle_tpl/ceilometer.yaml new file mode 100644 index 00000000..031551a5 --- /dev/null +++ b/ci/config_tpl/bundle_tpl/ceilometer.yaml @@ -0,0 +1,18 @@ + mongodb: + charm: local:{{ ubuntu.release }}/mongodb + to: + - "lxc:nodes=0" + ceilometer: + charm: "local:{{ ubuntu.release }}/ceilometer" + num_units: {{ unit_qty() }} + options: +{% if os.ha.mode == 'ha' %} + vip: {{ opnfv.vip.ceilometer }} +{% endif %} +{% if os.beta.public_api %} + os-public-hostname: api.{{ opnfv.domain }} +{% endif %} + to: +{% for unit_id in to_select() %} + - "lxc:nodes={{ unit_id }}" +{% endfor %} diff --git a/ci/config_tpl/bundle_tpl/ceph.yaml b/ci/config_tpl/bundle_tpl/ceph.yaml new file mode 100644 index 00000000..82cfd283 --- /dev/null +++ b/ci/config_tpl/bundle_tpl/ceph.yaml @@ -0,0 +1,36 @@ +{% if opnfv.storage_dict.ceph is defined %} + ceph: + charm: "local:{{ ubuntu.release }}/ceph" + num_units: {{ unit_ceph_qty() }} + options: + monitor-count: {{ unit_ceph_qty() }} + fsid: 5a791d94-980b-11e4-b6f6-3c970e8b1cf7 + monitor-secret: AQAi5a9UeJXUExAA+By9u+GPhl8/XiUQ4nwI3A== +{% if opnfv.spaces_dict.storage is defined %} + #ceph-cluster-network: {{ opnfv.spaces_dict.storage.cidr }} +{% endif %} + to: +{% for unit_id in to_select(unit_ceph_qty()) %} + - "lxc:nodes={{ unit_id }}" +{% endfor %} + ceph-osd: + charm: "local:{{ ubuntu.release }}/ceph-osd" + num_units: {{ opnfv.units }} + options: + osd-devices: {{ opnfv.storage_dict.ceph.disk }} + osd-reformat: 'yes' + to: +{% for unit_id in range(0, opnfv.units) %} + - "nodes={{ unit_id }}" +{% endfor %} + ceph-radosgw: + charm: "local:{{ ubuntu.release }}/ceph-radosgw" + num_units: {{ unit_qty() if os.beta.hacluster_ceph_radosgw else 1 }} + options: + use-embedded-webserver: true + operator-roles: "Member,admin" + to: +{% for unit_id in to_select(unit_qty() if os.beta.hacluster_ceph_radosgw else 1) %} + - "lxc:nodes={{ unit_id }}" +{% endfor %} +{% endif %} diff --git a/ci/config_tpl/bundle_tpl/cinder.yaml b/ci/config_tpl/bundle_tpl/cinder.yaml new file mode 100644 index 00000000..4c1b8623 --- /dev/null +++ b/ci/config_tpl/bundle_tpl/cinder.yaml @@ -0,0 +1,16 @@ + cinder: + charm: "local:{{ ubuntu.release }}/cinder" + num_units: {{ unit_qty() }} + options: +{% if os.beta.public_api %} + os-public-hostname: api.{{ opnfv.domain }} +{% endif %} + block-device: None + glance-api-version: 2 +{% if os.ha.mode == 'ha' %} + vip: {{ opnfv.vip.cinder }} +{% endif %} + to: +{% for unit_id in to_select() %} + - "lxc:nodes={{ unit_id }}" +{% endfor %} diff --git a/ci/config_tpl/bundle_tpl/congress.yaml b/ci/config_tpl/bundle_tpl/congress.yaml new file mode 100644 index 00000000..3d05295e --- /dev/null +++ b/ci/config_tpl/bundle_tpl/congress.yaml @@ -0,0 +1,9 @@ + congress: + charm: "local:{{ ubuntu.release }}/congress" +{% if ubuntu.release == 'trusty' %} + options: + source-branch: "stable/{{ os.release }}" +{% endif %} + to: + - "lxc:nodes=0" +{# Empty block to avoid bad block trim #} diff --git a/ci/config_tpl/bundle_tpl/glance.yaml b/ci/config_tpl/bundle_tpl/glance.yaml new file mode 100644 index 00000000..84999326 --- /dev/null +++ b/ci/config_tpl/bundle_tpl/glance.yaml @@ -0,0 +1,14 @@ + glance: + charm: "local:{{ ubuntu.release }}/glance" + num_units: {{ unit_qty() }} + options: +{% if os.ha.mode == 'ha' %} + vip: {{ opnfv.vip.glance }} +{% endif %} +{% if os.beta.public_api %} + os-public-hostname: api.{{ opnfv.domain }} +{% endif %} + to: +{% for unit_id in to_select() %} + - "lxc:nodes={{ unit_id }}" +{% endfor %} diff --git a/ci/config_tpl/bundle_tpl/haclusters.yaml b/ci/config_tpl/bundle_tpl/haclusters.yaml new file mode 100644 index 00000000..fc42d38e --- /dev/null +++ b/ci/config_tpl/bundle_tpl/haclusters.yaml @@ -0,0 +1,53 @@ + + hacluster-keystone: + charm: "local:{{ ubuntu.release }}/hacluster" + options: + corosync_transport: unicast + cluster_count: 3 + hacluster-cinder: + charm: "local:{{ ubuntu.release }}/hacluster" + options: + corosync_transport: unicast + cluster_count: 3 +# hacluster-heat: +# charm: "local:{{ ubuntu.release }}/hacluster" +# options: +# corosync_transport: unicast +# cluster_count: 3 + hacluster-horizon: + charm: "local:{{ ubuntu.release }}/hacluster" + options: + corosync_transport: unicast + cluster_count: 3 + hacluster-nova: + charm: "local:{{ ubuntu.release }}/hacluster" + options: + corosync_transport: unicast + cluster_count: 3 + hacluster-neutron: + charm: "local:{{ ubuntu.release }}/hacluster" + options: + corosync_transport: unicast + cluster_count: 3 + hacluster-glance: + charm: "local:{{ ubuntu.release }}/hacluster" + options: + corosync_transport: unicast + cluster_count: 3 + hacluster-ceilometer: + charm: "local:{{ ubuntu.release }}/hacluster" + options: + corosync_transport: unicast + cluster_count: 3 + hacluster-mysql: + charm: "local:{{ ubuntu.release }}/hacluster" + options: + corosync_transport: unicast + cluster_count: 3 +{% if os.beta.hacluster_ceph_radosgw %} + hacluster-ceph-radosgw: + charm: "local:{{ ubuntu.release }}/hacluster" + options: + corosync_transport: unicast + cluster_count: 3 +{% endif %} diff --git a/ci/config_tpl/bundle_tpl/harelations.yaml b/ci/config_tpl/bundle_tpl/harelations.yaml new file mode 100644 index 00000000..d4c4c064 --- /dev/null +++ b/ci/config_tpl/bundle_tpl/harelations.yaml @@ -0,0 +1,14 @@ +{% if os.ha.mode == 'ha' %} + - [ 'mysql:ha', 'hacluster-mysql:ha' ] + - [ 'cinder:ha', 'hacluster-cinder:ha' ] +# - [ 'heat:ha', 'hacluster-heat:ha' ] + - [ 'glance:ha', 'hacluster-glance:ha' ] + - [ 'keystone:ha', 'hacluster-keystone:ha' ] + - [ 'neutron-api:ha', 'hacluster-neutron:ha' ] + - [ 'nova-cloud-controller:ha', 'hacluster-nova:ha' ] + - [ 'openstack-dashboard:ha', 'hacluster-horizon:ha' ] + - [ 'ceilometer:ha', 'hacluster-ceilometer:ha' ] +{% if os.beta.hacluster_ceph_radosgw %} + - [ 'ceph-radosgw:ha', 'hacluster-ceph-radosgw:ha' ] +{% endif %} +{% endif %} diff --git a/ci/config_tpl/bundle_tpl/heat.yaml b/ci/config_tpl/bundle_tpl/heat.yaml new file mode 100644 index 00000000..4fe9deb7 --- /dev/null +++ b/ci/config_tpl/bundle_tpl/heat.yaml @@ -0,0 +1,13 @@ + heat: + charm: "local:{{ ubuntu.release }}/heat" +# num_units: {{ unit_qty() }} + options: +{% if os.ha.mode == 'ha' %} +# vip: {{ opnfv.vip.heat }} +{% endif %} +{% if os.beta.public_api %} +# os-public-hostname: api.{{ opnfv.domain }} +{% endif %} + to: + - "lxc:nodes=0" +{# Empty block to avoid bad block trim #} diff --git a/ci/config_tpl/bundle_tpl/keystone.yaml b/ci/config_tpl/bundle_tpl/keystone.yaml new file mode 100644 index 00000000..24f5b102 --- /dev/null +++ b/ci/config_tpl/bundle_tpl/keystone.yaml @@ -0,0 +1,16 @@ + keystone: + charm: "local:{{ ubuntu.release }}/keystone" + num_units: {{ unit_qty() }} + options: + admin-password: {{ opnfv.admin_password | default(os.admin.password) }} + admin-token: {{ os.admin.name }} +{% if os.ha.mode == 'ha' %} + vip: {{ opnfv.vip.keystone }} +{% endif %} +{% if os.beta.public_api %} + os-public-hostname: api.{{ opnfv.domain }} +{% endif %} + to: +{% for unit_id in to_select() %} + - "lxc:nodes={{ unit_id }}" +{% endfor %} diff --git a/ci/config_tpl/bundle_tpl/mysql.yaml b/ci/config_tpl/bundle_tpl/mysql.yaml new file mode 100644 index 00000000..110140e9 --- /dev/null +++ b/ci/config_tpl/bundle_tpl/mysql.yaml @@ -0,0 +1,17 @@ + mysql: + charm: "local:{{ ubuntu.release }}/percona-cluster" + num_units: {{ unit_qty() }} + options: + innodb-buffer-pool-size: 100M + #lp1366997-workaround: true + max-connections: 20000 + root-password: {{ get_password('mysql_root') }} + sst-password: {{ get_password('mysql_sst') }} +{% if os.ha.mode == 'ha' %} + vip: {{ opnfv.vip.mysql }} +{% endif %} + min-cluster-size: {{ unit_qty() }} + to: +{% for unit_id in to_select() %} + - "lxc:nodes={{ unit_id }}" +{% endfor %} diff --git a/ci/config_tpl/bundle_tpl/neutron-api.yaml b/ci/config_tpl/bundle_tpl/neutron-api.yaml new file mode 100644 index 00000000..9ee914ae --- /dev/null +++ b/ci/config_tpl/bundle_tpl/neutron-api.yaml @@ -0,0 +1,26 @@ + neutron-api: + charm: "local:{{ ubuntu.release }}/neutron-api" + num_units: {{ unit_qty() }} + options: + neutron-security-groups: true +{% if os.network.controller == 'nosdn' %} + flat-network-providers: "*" +{% if os.network.dvr %} + overlay-network-type: vxlan +{% endif %} +{% elif os.network.controller == 'odl' %} + manage-neutron-plugin-legacy-mode: False +{% elif os.network.controller == 'onos' %} + flat-network-providers: "*" + manage-neutron-plugin-legacy-mode: False +{% endif %} +{% if os.ha.mode == 'ha' %} + vip: {{ opnfv.vip.neutron }} +{% endif %} +{% if os.beta.public_api %} + os-public-hostname: api.{{ opnfv.domain }} +{% endif %} + to: +{% for unit_id in to_select() %} + - "lxc:nodes={{ unit_id }}" +{% endfor %} diff --git a/ci/config_tpl/bundle_tpl/neutron-gateway.yaml b/ci/config_tpl/bundle_tpl/neutron-gateway.yaml new file mode 100644 index 00000000..74743ef7 --- /dev/null +++ b/ci/config_tpl/bundle_tpl/neutron-gateway.yaml @@ -0,0 +1,46 @@ + neutron-gateway: + charm: "local:{{ ubuntu.release }}/neutron-gateway" + options: +{% if opnfv.spaces_dict.data is defined %} + os-data-network: {{ opnfv.spaces_dict.data.cidr }} +{% else %} + #os-data-network: {{ opnfv.spaces_dict.data.cidr }} +{% endif %} +{% if os.network.controller == 'nosdn' %} +{% if opnfv.ext_port is defined %} +{% if opnfv.data_port is defined %} + bridge-mappings: physnet1:br-data external:br-ex + data-port: br-data:{{ opnfv.data_port }} br-ex:{{ opnfv.ext_port }} +{% else %} + bridge-mappings: external:br-ex + data-port: br-ex:{{ opnfv.ext_port }} +{% endif %} +{% endif %} +{% elif os.network.controller == 'onos' %} + plugin: onos +{% if opnfv.ext_port is defined %} +{% if opnfv.data_port is defined %} + bridge-mappings: physnet1:br-data external:br-ex + data-port: br-data:{{ opnfv.data_port }} br-ex:{{ opnfv.ext_port }} +{% else %} + bridge-mappings: external:br-ex + data-port: br-ex:{{ opnfv.ext_port }} +{% endif %} +{% endif %} +{% if os.network.sfc %} + profile: onos-sfc +{% endif %} +{% elif os.network.controller == 'odl' %} + plugin: ovs-odl +{% if opnfv.ext_port is defined %} + ext-port: {{ opnfv.ext_port }} +{% endif %} +{% else %} +{% if opnfv.ext_port is defined %} + ext-port: {{ opnfv.ext_port }} +{% endif %} +{% endif %} + instance-mtu: 1400 + to: + - "nodes=0" +{# Empty block to avoid bad block trim #} diff --git a/ci/config_tpl/bundle_tpl/neutron-ovs.yaml b/ci/config_tpl/bundle_tpl/neutron-ovs.yaml new file mode 100644 index 00000000..087783d8 --- /dev/null +++ b/ci/config_tpl/bundle_tpl/neutron-ovs.yaml @@ -0,0 +1,31 @@ + neutron-openvswitch: + charm: local:{{ ubuntu.release }}/neutron-openvswitch + options: +{% if opnfv.spaces_dict.data is defined %} + os-data-network: {{ opnfv.spaces_dict.data.cidr }} +{% else %} + #os-data-network: {{ opnfv.spaces_dict.data.cidr }} +{% endif %} +{% if os.network.dpdk %} + enable-dpdk: true + #dpdk-driver: uio_pci_generic + #data-port: "" + #default-socket-memory: 1024 + #default-socket-cores: 1 +{% endif %} +{% if opnfv.ext_port is defined %} +{% if os.network.dvr %} +{% if os.network.controller == 'nosdn' %} +{% if opnfv.data_port is defined %} + bridge-mappings: physnet1:br-data external:br-ex + data-port: br-data:{{ opnfv.data_port }} br-ex:{{ opnfv.ext_port }} +{% else %} + bridge-mappings: external:br-ex + data-port: br-ex:{{ opnfv.ext_port }} +{% endif %} +{% else %} + ext-port: {{ opnfv.ext_port }} +{% endif %} +{% endif %} +{% endif %} +{# Empty block to avoid bad block trim #} diff --git a/ci/config_tpl/bundle_tpl/nova-cloud-controller.yaml b/ci/config_tpl/bundle_tpl/nova-cloud-controller.yaml new file mode 100644 index 00000000..bdf1090a --- /dev/null +++ b/ci/config_tpl/bundle_tpl/nova-cloud-controller.yaml @@ -0,0 +1,21 @@ + nova-cloud-controller: + charm: "local:{{ ubuntu.release }}/nova-cloud-controller" + num_units: {{ unit_qty() }} + options: + #console-access-protocol: novnc + neutron-external-network: ext-net + service-guard: true +{% if opnfv.domain is defined %} + console-proxy-ip: {{ opnfv.domain }} +{% endif %} + network-manager: Neutron +{% if os.ha.mode == 'ha' %} + vip: {{ opnfv.vip.nova }} +{% endif %} +{% if os.beta.public_api %} + os-public-hostname: api.{{ opnfv.domain }} +{% endif %} + to: +{% for unit_id in to_select() %} + - "lxc:nodes={{ unit_id }}" +{% endfor %} diff --git a/ci/config_tpl/bundle_tpl/nova-compute.yaml b/ci/config_tpl/bundle_tpl/nova-compute.yaml new file mode 100644 index 00000000..81803807 --- /dev/null +++ b/ci/config_tpl/bundle_tpl/nova-compute.yaml @@ -0,0 +1,18 @@ + nova-compute: + charm: "local:{{ ubuntu.release }}/nova-compute" + num_units: {{ opnfv.units - 1 }} + options: + enable-live-migration: true + enable-resize: true + manage-neutron-plugin-legacy-mode: false + migration-auth-type: ssh +{% if os.beta.huge_pages %} + hugepages: "50%" +{% endif %} +{% if os.lxd %} + virt-type: lxd +{% endif %} + to: +{% for unit_id in range(1, opnfv.units) %} + - "nodes={{ unit_id }}" +{% endfor %} diff --git a/ci/config_tpl/bundle_tpl/oclphase1.yaml b/ci/config_tpl/bundle_tpl/oclphase1.yaml new file mode 100644 index 00000000..afef96c0 --- /dev/null +++ b/ci/config_tpl/bundle_tpl/oclphase1.yaml @@ -0,0 +1,58 @@ + zookeeper: + charm: local:precise/zookeeper + num_units: {{ unit_qty() }} + series: precise + to: +{% for unit_id in to_select() %} + - "lxc:nodes={{ unit_id }}" +{% endfor %} + cassandra: + charm: local:{{ ubuntu.release }}/cassandra + num_units: {{ unit_qty() }} + to: +{% for unit_id in to_select() %} + - "lxc:nodes={{ unit_id }}" +{% endfor %} + options: + authenticator: AllowAllAuthenticator + contrail-configuration: + charm: local:{{ ubuntu.release }}/contrail-configuration + num_units: {{ unit_qty() }} + options: +{% if os.ha.mode == 'ha' %} + vip: {{ opnfv.vip.contrailconfig }} +{% endif %} + to: +{% for unit_id in to_select() %} + - "lxc:nodes={{ unit_id }}" +{% endfor %} + contrail-control: + charm: local:{{ ubuntu.release }}/contrail-control + num_units: {{ unit_qty() }} + to: +{% for unit_id in to_select() %} + - "lxc:nodes={{ unit_id }}" +{% endfor %} + contrail-analytics: + charm: local:{{ ubuntu.release }}/contrail-analytics + num_units: {{ unit_qty() }} + to: +{% for unit_id in to_select() %} + - "lxc:nodes={{ unit_id }}" +{% endfor %} + contrail-webui: + charm: local:{{ ubuntu.release }}/contrail-webui + num_units: {{ unit_qty() }} + to: +{% for unit_id in to_select() %} + - "lxc:nodes={{ unit_id }}" +{% endfor %} + haproxy: + charm: local:{{ ubuntu.release }}/haproxy + num_units: {{ unit_qty() }} + options: + peering_mode: active-active + to: +{% for unit_id in to_select() %} + - "lxc:nodes={{ unit_id }}" +{% endfor %} diff --git a/ci/config_tpl/bundle_tpl/odl.yaml b/ci/config_tpl/bundle_tpl/odl.yaml new file mode 100644 index 00000000..30f555c9 --- /dev/null +++ b/ci/config_tpl/bundle_tpl/odl.yaml @@ -0,0 +1,17 @@ + odl-controller: + charm: local:{{ ubuntu.release }}/odl-controller + options: + install-url: "https://nexus.opendaylight.org/content/repositories/opendaylight.release/org/opendaylight/integration/distribution-karaf/0.4.2-Beryllium-SR2/distribution-karaf-0.4.2-Beryllium-SR2.tar.gz" +{% if os.network.sfc %} + profile: "openvswitch-odl-beryllium-sfc" +{% elif os.network.bgpvpn %} + profile: "openvswitch-odl-beryllium-vpn" +{% elif os.network.odll3 %} + profile: "openvswitch-odl-beryllium-l3" +{% else %} + profile: "openvswitch-odl-beryllium" +{% endif %} + http-proxy: "http://squid.internal:3128" + https-proxy: "http://squid.internal:3128" + to: + - "lxc:nodes=0" diff --git a/ci/config_tpl/bundle_tpl/onos.yaml b/ci/config_tpl/bundle_tpl/onos.yaml new file mode 100644 index 00000000..fd08c717 --- /dev/null +++ b/ci/config_tpl/bundle_tpl/onos.yaml @@ -0,0 +1,9 @@ + onos-controller: + charm: local:{{ ubuntu.release }}/onos-controller + options: +{% if opnfv.ext_port is defined %} + ext-port: {{ opnfv.ext_port }} +{% endif %} + #gateway-mac: "default" + to: + - "lxc:nodes=0" diff --git a/ci/config_tpl/bundle_tpl/openstack-dashboard.yaml b/ci/config_tpl/bundle_tpl/openstack-dashboard.yaml new file mode 100644 index 00000000..83408dcd --- /dev/null +++ b/ci/config_tpl/bundle_tpl/openstack-dashboard.yaml @@ -0,0 +1,16 @@ + openstack-dashboard: + charm: "local:{{ ubuntu.release }}/openstack-dashboard" + num_units: {{ unit_qty() }} + options: + secret: admin + webroot: / +{% if os.ha.mode == 'ha' %} + vip: {{ opnfv.vip.dashboard }} +{% endif %} +{% if os.beta.public_api %} + endpoint-type: internalURL +{% endif %} + to: +{% for unit_id in to_select() %} + - "lxc:nodes={{ unit_id }}" +{% endfor %} diff --git a/ci/config_tpl/bundle_tpl/opnfv-promise.yaml b/ci/config_tpl/bundle_tpl/opnfv-promise.yaml new file mode 100644 index 00000000..4e96cf73 --- /dev/null +++ b/ci/config_tpl/bundle_tpl/opnfv-promise.yaml @@ -0,0 +1,5 @@ + opnfv-promise: + charm: local:{{ ubuntu.release }}/promise + to: + - "lxc:nodes=0" +{# Empty block to avoid bad block trim #} diff --git a/ci/config_tpl/bundle_tpl/phase2-overrides.yaml b/ci/config_tpl/bundle_tpl/phase2-overrides.yaml new file mode 100644 index 00000000..33350300 --- /dev/null +++ b/ci/config_tpl/bundle_tpl/phase2-overrides.yaml @@ -0,0 +1,25 @@ +{% if opnfv.spaces_dict.storage is defined %} + #ceph-cluster-network: {{ opnfv.spaces_dict.storage.cidr }} +{% endif %} +{% if os.network.ipv6 %} + prefer-ipv6: {{ os.network.ipv6 }} +{% endif %} +{% if os.network.dvr %} + enable-dvr: true +{% endif %} +{% if os.network.l2_population %} + l2-population: true +{% endif %} + region: {{ os.region }} +{% if ubuntu.release == 'trusty' %} + source: "cloud:{{ ubuntu.release }}-{{ os.release }}" +{% endif %} + openstack-origin: "cloud:{{ ubuntu.release }}-{{ os.release }}" +{% if os.ha.mode == 'nonha' %} + ceph-osd-replication-count: {{ unit_ceph_qty() }} +{% endif %} + admin-role: {{ os.admin.role }} + keystone-admin-role: {{ os.admin.role }} +{% if os.beta.public_api %} + use-internal-endpoints: true +{% endif %} diff --git a/ci/config_tpl/bundle_tpl/rabbitmq.yaml b/ci/config_tpl/bundle_tpl/rabbitmq.yaml new file mode 100644 index 00000000..1020340f --- /dev/null +++ b/ci/config_tpl/bundle_tpl/rabbitmq.yaml @@ -0,0 +1,12 @@ + rabbitmq-server: + charm: "local:{{ ubuntu.release }}/rabbitmq-server" + num_units: {{ unit_qty() }} + options: +{% if os.ha.mode == 'ha' %} + vip: {{ opnfv.vip.rabbitmq }} + min-cluster-size: {{ unit_qty() }} +{% endif %} + to: +{% for unit_id in to_select() %} + - "lxc:nodes={{ unit_id }}" +{% endfor %} diff --git a/ci/config_tpl/bundle_tpl/relations.yaml b/ci/config_tpl/bundle_tpl/relations.yaml new file mode 100644 index 00000000..4cf24385 --- /dev/null +++ b/ci/config_tpl/bundle_tpl/relations.yaml @@ -0,0 +1,95 @@ + - [ 'nova-compute:amqp', 'rabbitmq-server:amqp' ] + - [ 'neutron-gateway:amqp', 'rabbitmq-server:amqp' ] + - [ 'keystone:shared-db', 'mysql:shared-db' ] + - [ 'nova-cloud-controller:identity-service', 'keystone:identity-service' ] + - [ 'glance:identity-service', 'keystone:identity-service' ] + - [ 'neutron-api:identity-service', 'keystone:identity-service' ] + - [ 'neutron-api:shared-db', 'mysql:shared-db' ] + - [ 'neutron-api:amqp', 'rabbitmq-server:amqp' ] + - [ 'neutron-gateway:neutron-plugin-api', 'neutron-api:neutron-plugin-api' ] + - [ 'glance:shared-db', 'mysql:shared-db' ] + - [ 'glance:amqp', 'rabbitmq-server:amqp' ] + - [ 'nova-cloud-controller:image-service', 'glance:image-service' ] + - [ 'nova-compute:image-service', 'glance:image-service' ] + - [ 'nova-cloud-controller:cloud-compute', 'nova-compute:cloud-compute' ] + - [ 'nova-cloud-controller:amqp', 'rabbitmq-server:amqp' ] + - [ 'nova-cloud-controller:quantum-network-service', 'neutron-gateway:quantum-network-service' ] + - [ 'openstack-dashboard:identity-service', 'keystone:identity-service' ] + - [ 'nova-cloud-controller:shared-db', 'mysql:shared-db' ] + - [ 'nova-cloud-controller:neutron-api', 'neutron-api:neutron-api' ] + - [ 'cinder:image-service', 'glance:image-service' ] + - [ 'cinder:amqp', 'rabbitmq-server:amqp' ] + - [ 'cinder:identity-service', 'keystone:identity-service' ] + - [ 'cinder:cinder-volume-service', 'nova-cloud-controller:cinder-volume-service' ] + - [ 'cinder-ceph:storage-backend', 'cinder:storage-backend' ] + - [ 'ceph:client', 'nova-compute:ceph' ] + - [ 'cinder:shared-db', 'mysql:shared-db' ] + - [ 'ceph:client', 'cinder-ceph:ceph' ] + - [ 'ceph:client', 'glance:ceph' ] + - [ 'ceph-osd:mon', 'ceph:osd' ] + - [ 'ceph-radosgw:mon', 'ceph:radosgw' ] + - [ 'ceph-radosgw:identity-service', 'keystone:identity-service' ] + - [ 'ceilometer:amqp', 'rabbitmq-server:amqp' ] + - [ 'ceilometer-agent:ceilometer-service', 'ceilometer:ceilometer-service' ] + - [ 'ceilometer:identity-service', 'keystone:identity-service' ] + - [ 'ceilometer:identity-notifications', 'keystone:identity-notifications' ] + - [ 'ceilometer-agent:nova-ceilometer', 'nova-compute:nova-ceilometer' ] + - [ 'ceilometer:shared-db', 'mongodb:database' ] + - [ 'heat:shared-db', 'mysql:shared-db' ] + - [ 'heat:identity-service', 'keystone:identity-service' ] + - [ 'heat:amqp', 'rabbitmq-server:amqp' ] + - [ 'congress:shared-db', 'mysql:shared-db' ] + - [ 'congress:identity-service', 'keystone:identity-service' ] + - [ 'congress:amqp', 'rabbitmq-server:amqp' ] + - [ 'aodh:amqp', 'rabbitmq-server:amqp' ] + - [ 'aodh:shared-db', 'mysql:shared-db' ] + - [ 'aodh:identity-service', 'keystone:identity-service' ] +{% if os.lxd %} + - [ 'nova-compute:lxd', 'lxd:lxd' ] +{% endif %} +{% if os.network.controller == 'nosdn' %} + - [ 'neutron-openvswitch:amqp', 'rabbitmq-server:amqp' ] + - [ 'nova-compute:neutron-plugin', 'neutron-openvswitch:neutron-plugin' ] + - [ 'neutron-openvswitch:neutron-plugin-api', 'neutron-api:neutron-plugin-api' ] +{% elif os.network.controller == 'odl' %} + - [ 'neutron-api:neutron-plugin-api-subordinate', 'neutron-api-odl:neutron-plugin-api-subordinate' ] + - [ 'nova-compute:neutron-plugin', 'openvswitch-odl:neutron-plugin' ] + - [ 'neutron-gateway', 'openvswitch-odl' ] + - [ 'openvswitch-odl:ovsdb-manager', 'odl-controller:ovsdb-manager' ] + - [ 'neutron-api-odl:odl-controller', 'odl-controller:controller-api' ] +{% elif os.network.controller == 'onos' %} + - [ 'neutron-api:neutron-plugin-api-subordinate', 'neutron-api-onos:neutron-plugin-api-subordinate' ] + - [ 'nova-compute:neutron-plugin', 'openvswitch-onos:neutron-plugin' ] + - [ 'neutron-gateway', 'openvswitch-onos' ] + - [ 'openvswitch-onos:ovsdb-manager', 'onos-controller:ovsdb-manager' ] + - [ 'neutron-api-onos:onos-controller', 'onos-controller:controller-api' ] +{% elif os.network.controller == 'ocl' %} + - [ 'contrail-configuration:cassandra', 'cassandra:database' ] + - [ 'contrail-configuration', 'zookeeper' ] + - [ 'contrail-configuration', 'rabbitmq-server' ] + - [ 'contrail-configuration', 'keystone' ] + - [ 'neutron-api-contrail', 'contrail-configuration' ] + - [ 'neutron-api-contrail', 'keystone' ] + - [ 'contrail-control:contrail-api', 'contrail-configuration:contrail-api' ] + - [ 'contrail-control:contrail-discovery', 'contrail-configuration:contrail-discovery' ] + - [ 'contrail-control:contrail-ifmap', 'contrail-configuration:contrail-ifmap' ] + - [ 'contrail-control', 'keystone' ] + - [ 'contrail-analytics:cassandra', 'cassandra:database' ] + - [ 'contrail-analytics:contrail-analytics-api', 'contrail-configuration:contrail-analytics-api' ] + - [ 'contrail-configuration:contrail-discovery', 'contrail-analytics:contrail-discovery' ] + - [ 'contrail-webui', 'keystone' ] + - [ 'contrail-webui:contrail_api', 'contrail-configuration:contrail-api' ] + - [ 'contrail-webui:contrail_discovery', 'contrail-configuration:contrail-discovery' ] + - [ 'contrail-webui:cassandra', 'cassandra:database' ] + - [ 'nova-compute', 'neutron-contrail' ] + - [ 'neutron-contrail:contrail-discovery', 'contrail-configuration:contrail-discovery' ] + - [ 'neutron-contrail:contrail-api', 'contrail-configuration:contrail-api' ] + - [ 'neutron-contrail', 'keystone' ] + - [ 'contrail-configuration', 'ntp' ] + - [ 'contrail-control', 'ntp' ] + - [ 'contrail-analytics', 'ntp' ] + - [ 'contrail-configuration', 'haproxy' ] + - [ 'contrail-analytics', 'haproxy' ] + - [ 'contrail-webui', 'haproxy' ] + - [ 'haproxy', 'keepalived' ] +{% endif %} diff --git a/ci/config_tpl/bundle_tpl/subordinate.yaml b/ci/config_tpl/bundle_tpl/subordinate.yaml new file mode 100644 index 00000000..aea5232c --- /dev/null +++ b/ci/config_tpl/bundle_tpl/subordinate.yaml @@ -0,0 +1,55 @@ + ceilometer-agent: + charm: local:{{ ubuntu.release }}/ceilometer-agent +{% if opnfv.storage_dict.ceph is defined %} + cinder-ceph: + charm: local:{{ ubuntu.release }}/cinder-ceph +{% endif %} +{% if os.network.controller == 'nosdn' %} +{% include 'neutron-ovs.yaml' %} +{% elif os.network.controller == 'odl' %} + neutron-api-odl: + charm: local:{{ ubuntu.release }}/neutron-api-odl + options: + overlay-network-type: 'vxlan' + security-groups: True + openvswitch-odl: + charm: local:{{ ubuntu.release }}/openvswitch-odl + options: +{% if opnfv.spaces_dict.data is defined %} + os-data-network: {{ opnfv.spaces_dict.data.cidr }} +{% else %} + #os-data-network: {{ opnfv.spaces_dict.data.cidr }} +{% endif %} +{% elif os.network.controller == 'onos' %} + neutron-api-onos: + charm: local:{{ ubuntu.release }}/neutron-api-onos + options: + overlay-network-type: 'vxlan' + security-groups: True + openvswitch-onos: + charm: local:{{ ubuntu.release }}/openvswitch-onos + options: +{% if opnfv.spaces_dict.data is defined %} + os-data-network: {{ opnfv.spaces_dict.data.cidr }} +{% else %} + #os-data-network: {{ opnfv.spaces_dict.data.cidr }} +{% endif %} +{% if os.network.sfc %} + profile: onos-sfc +{% endif %} +{% elif os.network.controller == 'ocl' %} + neutron-api-contrail: + charm: local:{{ ubuntu.release }}/neutron-api-contrail + neutron-contrail: + charm: local:{{ ubuntu.release }}/neutron-contrail + keepalived: + charm: local:{{ ubuntu.release }}/keepalived + options: +{% if os.ha.mode == 'ha' %} + virtual-ip: {{ opnfv.vip.keepalived }} +{% endif %} +{% endif %} +{% if os.lxd %} + lxd: + charm: local:{{ ubuntu.release }}/lxd +{% endif %} -- cgit 1.2.3-korg