aboutsummaryrefslogtreecommitdiffstats
path: root/charms/trusty/neutron-contrail/templates
diff options
context:
space:
mode:
Diffstat (limited to 'charms/trusty/neutron-contrail/templates')
-rw-r--r--charms/trusty/neutron-contrail/templates/contrail-barbican-auth.conf13
-rw-r--r--charms/trusty/neutron-contrail/templates/contrail-vrouter-agent.conf44
-rw-r--r--charms/trusty/neutron-contrail/templates/contrail-vrouter-nodemgr.conf9
-rw-r--r--charms/trusty/neutron-contrail/templates/vnc_api_lib.ini16
-rw-r--r--charms/trusty/neutron-contrail/templates/vrouter-vgw.cfg21
5 files changed, 103 insertions, 0 deletions
diff --git a/charms/trusty/neutron-contrail/templates/contrail-barbican-auth.conf b/charms/trusty/neutron-contrail/templates/contrail-barbican-auth.conf
new file mode 100644
index 0000000..84ab4a0
--- /dev/null
+++ b/charms/trusty/neutron-contrail/templates/contrail-barbican-auth.conf
@@ -0,0 +1,13 @@
+###############################################################################
+# [ WARNING ]
+# Configuration file maintained by Juju. Local changes may be overwritten.
+###############################################################################
+
+[DEFAULT]
+auth_url = http://{{ auth_host }}:{{ auth_port }}/v2.0
+auth_version = 2
+admin_user = {{ admin_user }}
+admin_password = {{ admin_password }}
+admin_tenant_name = {{ admin_tenant_name }}
+region = {{ auth_region }}
+
diff --git a/charms/trusty/neutron-contrail/templates/contrail-vrouter-agent.conf b/charms/trusty/neutron-contrail/templates/contrail-vrouter-agent.conf
new file mode 100644
index 0000000..3543c2d
--- /dev/null
+++ b/charms/trusty/neutron-contrail/templates/contrail-vrouter-agent.conf
@@ -0,0 +1,44 @@
+###############################################################################
+# [ WARNING ]
+# Configuration file maintained by Juju. Local changes may be overwritten.
+###############################################################################
+
+{%- if control_nodes %}
+
+[CONTROL-NODE]
+server = {{ control_nodes|join(" ") }}
+
+{%- endif %}
+{%- if discovery_server %}
+
+[DISCOVERY]
+server = {{ discovery_server }}
+
+{%- endif %}
+
+[METADATA]
+metadata_proxy_secret = {{ metadata_secret }}
+
+[NETWORKS]
+control_network_ip = {{ control_network_ip }}
+
+[VIRTUAL-HOST-INTERFACE]
+name = vhost0
+ip = {{ vhost_ip }}
+gateway = {{ vhost_gateway }}
+physical_interface = {{ vhost_physical }}
+
+{%- for vgw in vgws %}
+
+[GATEWAY-{{ loop.index0 }}]
+routing_instance = {{ vgw["domain"] }}:{{ vgw["project"] }}:{{ vgw["network"] }}:{{ vgw["network"] }}
+interface = {{ vgw["interface"] }}
+ip_blocks = {{ vgw["subnets"]|join(" ") }}
+routes = {{ vgw["routes"]|join(" ") }}
+
+{%- endfor %}
+
+[SERVICE-INSTANCE]
+netns_command = /usr/bin/opencontrail-vrouter-netns
+docker_command = /usr/bin/opencontrail-vrouter-docker
+
diff --git a/charms/trusty/neutron-contrail/templates/contrail-vrouter-nodemgr.conf b/charms/trusty/neutron-contrail/templates/contrail-vrouter-nodemgr.conf
new file mode 100644
index 0000000..ffea798
--- /dev/null
+++ b/charms/trusty/neutron-contrail/templates/contrail-vrouter-nodemgr.conf
@@ -0,0 +1,9 @@
+###############################################################################
+# [ WARNING ]
+# Configuration file maintained by Juju. Local changes may be overwritten.
+###############################################################################
+
+[DISCOVERY]
+server = {{ discovery_server }}
+port = {{ discovery_port }}
+
diff --git a/charms/trusty/neutron-contrail/templates/vnc_api_lib.ini b/charms/trusty/neutron-contrail/templates/vnc_api_lib.ini
new file mode 100644
index 0000000..fd68487
--- /dev/null
+++ b/charms/trusty/neutron-contrail/templates/vnc_api_lib.ini
@@ -0,0 +1,16 @@
+###############################################################################
+# [ WARNING ]
+# Configuration file maintained by Juju. Local changes may be overwritten.
+###############################################################################
+
+[global]
+WEB_SERVER = {{ api_server }}
+WEB_PORT = {{ api_port }}
+
+[auth]
+AUTHN_TYPE = keystone
+AUTHN_PROTOCOL = http
+AUTHN_SERVER = {{ auth_host }}
+AUTHN_PORT = {{ auth_port }}
+AUTHN_URL = /v2.0/tokens
+
diff --git a/charms/trusty/neutron-contrail/templates/vrouter-vgw.cfg b/charms/trusty/neutron-contrail/templates/vrouter-vgw.cfg
new file mode 100644
index 0000000..f5afd46
--- /dev/null
+++ b/charms/trusty/neutron-contrail/templates/vrouter-vgw.cfg
@@ -0,0 +1,21 @@
+###############################################################################
+# [ WARNING ]
+# Configuration file maintained by Juju. Local changes may be overwritten.
+###############################################################################
+
+{%- for vgw in vgws %}
+{% set interface = vgw["interface"] %}
+auto {{ interface }}
+iface {{ interface }} inet manual
+ pre-up vif --create {{ interface }} --mac 00:00:5e:00:01:00
+{%- for subnet in vgw["subnets"] %}
+ post-up route add -net {{ subnet }} dev {{ interface }}
+{%- endfor %}
+{%- for subnet in vgw["subnets"] %}
+ pre-down route del -net {{ subnet }} dev {{ interface }}
+{%- endfor %}
+ post-down id=$(vif --list | awk '/vif[0-9\/]+[\t ]+ OS: {{ interface }}/ { split($1, arr, "/"); print arr[2]; }'); \
+ { [ -n "$id" ] && vif --delete $id; } || true
+ post-down ip link delete {{ interface }}
+{%- endfor %}
+