summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--playbooks/provisioning/openstack/post-provision-openstack.yml2
-rw-r--r--playbooks/provisioning/openstack/sample-inventory/group_vars/all.yml4
-rw-r--r--roles/openstack-stack/templates/heat_stack.yaml.j211
3 files changed, 8 insertions, 9 deletions
diff --git a/playbooks/provisioning/openstack/post-provision-openstack.yml b/playbooks/provisioning/openstack/post-provision-openstack.yml
index 8d4ba3c12..460c6596b 100644
--- a/playbooks/provisioning/openstack/post-provision-openstack.yml
+++ b/playbooks/provisioning/openstack/post-provision-openstack.yml
@@ -14,7 +14,7 @@
become: true
roles:
- role: subscription-manager
- when: hostvars.localhost.rhsm_register
+ when: hostvars.localhost.rhsm_register|default(False)
tags: 'subscription-manager'
- name: Determine which DNS server(s) to use for our generated records
diff --git a/playbooks/provisioning/openstack/sample-inventory/group_vars/all.yml b/playbooks/provisioning/openstack/sample-inventory/group_vars/all.yml
index 7c9033828..c7e54f6cb 100644
--- a/playbooks/provisioning/openstack/sample-inventory/group_vars/all.yml
+++ b/playbooks/provisioning/openstack/sample-inventory/group_vars/all.yml
@@ -56,5 +56,5 @@ openstack_subnet_prefix: "192.168.99"
# hardcoded to `openshift`.
ansible_user: openshift
-# # Use a single security group for a cluster
-openstack_flat_secgrp: false
+# # Use a single security group for a cluster (default: false)
+#openstack_flat_secgrp: false
diff --git a/roles/openstack-stack/templates/heat_stack.yaml.j2 b/roles/openstack-stack/templates/heat_stack.yaml.j2
index 8bf76b57c..566b57ef8 100644
--- a/roles/openstack-stack/templates/heat_stack.yaml.j2
+++ b/roles/openstack-stack/templates/heat_stack.yaml.j2
@@ -160,7 +160,7 @@ resources:
protocol: icmp
remote_ip_prefix: {{ ssh_ingress_cidr }}
-{% if openstack_flat_secgrp|bool %}
+{% if openstack_flat_secgrp|default(False)|bool %}
flat-secgrp:
type: OS::Neutron::SecurityGroup
properties:
@@ -481,7 +481,7 @@ resources:
net: { get_resource: net }
subnet: { get_resource: subnet }
secgrp:
- - { get_resource: {% if openstack_flat_secgrp|bool %}flat-secgrp{% else %}etcd-secgrp{% endif %} }
+ - { get_resource: {% if openstack_flat_secgrp|default(False)|bool %}flat-secgrp{% else %}etcd-secgrp{% endif %} }
- { get_resource: common-secgrp }
floating_network: {{ external_network }}
net_name:
@@ -563,7 +563,7 @@ resources:
net: { get_resource: net }
subnet: { get_resource: subnet }
secgrp:
-{% if openstack_flat_secgrp|bool %}
+{% if openstack_flat_secgrp|default(False)|bool %}
- { get_resource: flat-secgrp }
{% else %}
- { get_resource: master-secgrp }
@@ -617,7 +617,7 @@ resources:
net: { get_resource: net }
subnet: { get_resource: subnet }
secgrp:
- - { get_resource: {% if openstack_flat_secgrp|bool %}flat-secgrp{% else %}node-secgrp{% endif %} }
+ - { get_resource: {% if openstack_flat_secgrp|default(False)|bool %}flat-secgrp{% else %}node-secgrp{% endif %} }
- { get_resource: common-secgrp }
floating_network: {{ external_network }}
net_name:
@@ -662,7 +662,7 @@ resources:
subnet: { get_resource: subnet }
secgrp:
# TODO(bogdando) filter only required node rules into infra-secgrp
-{% if openstack_flat_secgrp|bool %}
+{% if openstack_flat_secgrp|default(False)|bool %}
- { get_resource: flat-secgrp }
{% else %}
- { get_resource: node-secgrp }
@@ -718,4 +718,3 @@ resources:
volume_size: {{ dns_volume_size }}
depends_on:
- interface
-