summaryrefslogtreecommitdiffstats
path: root/ci/config_tpl/juju2/bundlek8_tpl/etcd.yaml
diff options
context:
space:
mode:
authorNarinder Gupta <narinder.gupta@canonical.com>2016-12-23 12:47:49 -0600
committerNarinder Gupta <narinder.gupta@canonical.com>2016-12-23 12:51:49 -0600
commit3470a4a0d81047d9d65a4b1e1e3b18e47865d4b6 (patch)
tree1744fd06855748c57a543b21188b784bebb8f386 /ci/config_tpl/juju2/bundlek8_tpl/etcd.yaml
parentf2fee53204aa7f3f8fe532b0394b60300a7f96f6 (diff)
modified to add load balancer kubernetes.
Change-Id: I87218dd9717c386db1ea721821d0d0e1bf4a08f9 Signed-off-by: Narinder Gupta <narinder.gupta@canonical.com>
Diffstat (limited to 'ci/config_tpl/juju2/bundlek8_tpl/etcd.yaml')
-rw-r--r--ci/config_tpl/juju2/bundlek8_tpl/etcd.yaml10
1 files changed, 10 insertions, 0 deletions
diff --git a/ci/config_tpl/juju2/bundlek8_tpl/etcd.yaml b/ci/config_tpl/juju2/bundlek8_tpl/etcd.yaml
index ba99d0e9..eaea9543 100644
--- a/ci/config_tpl/juju2/bundlek8_tpl/etcd.yaml
+++ b/ci/config_tpl/juju2/bundlek8_tpl/etcd.yaml
@@ -1,6 +1,16 @@
etcd:
charm: "./{{ ubuntu.release }}/etcd"
+{% if os.kubernetes.loadbalancer %}
+ num_units: 3
+{% else %}
num_units: 1
+{% endif %}
to:
+{% if os.kubernetes.loadbalancer %}
+{% for unit_id in to_select() %}
+ - "nodes/{{ unit_id }}"
+{% endfor %}
+{% else %}
- "nodes/0"
+{% endif %}