Skip to content

Commit 27422d6

Browse files
authored
Merge pull request #293 from jprovaznik/subd
Make app_subdomain customizable
2 parents c0df62f + 79d98ed commit 27422d6

4 files changed

Lines changed: 17 additions & 1 deletion

File tree

fragments/bastion-ansible.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,7 @@ function create_metadata_json() {
5858
"new_nodes": [$new_nodes],
5959
"deploy_router_or_registry": $deploy_router_or_registry,
6060
"domainname": "$domainname",
61+
"app_subdomain": "${app_subdomain:-"cloudapps.$domainname"}",
6162
"lb_hostname": "$lb_hostname",
6263
"short_lb_hostname": "${lb_hostname%%.$domainname}",
6364
"deploy_router": $([ "$deploy_router" == "True" ] && echo true || echo false),

node.yaml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -135,6 +135,12 @@ parameters:
135135
The DNS domain suffix. All VMs will be placed in this domain
136136
type: string
137137

138+
app_subdomain:
139+
type: string
140+
description: >
141+
Default subdomain to use for exposed routes.
142+
default: ''
143+
138144
ansible_public_key:
139145
description: >
140146
The SSH public key that Ansible will use to access master and node hosts
@@ -631,6 +637,8 @@ resources:
631637
- name: all_infra_nodes
632638
- name: domainname
633639
default: {get_param: domain_name}
640+
- name: app_subdomain
641+
default: {get_param: app_subdomain}
634642
- name: ssh_user
635643
default: {get_param: ssh_user}
636644
- name: deployment_type

openshift.yaml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -193,6 +193,12 @@ parameters:
193193
description: >
194194
The domain name that is going to be used as the base for all hostnames.
195195
196+
app_subdomain:
197+
type: string
198+
description: >
199+
Default subdomain to use for exposed routes.
200+
default: ''
201+
196202
lb_hostname:
197203
type: string
198204
description: >
@@ -666,6 +672,7 @@ resources:
666672
'%stackname%': {get_param: 'OS::stack_name'}
667673
'%hostname%': {get_param: node_hostname}
668674
domain_name: {get_param: domain_name}
675+
app_subdomain: {get_param: app_subdomain}
669676
ansible_public_key: {get_attr: [ansible_keys, public_key]}
670677
bastion_node: {get_attr: [bastion_host, resource.host]}
671678
skip_dns: {get_param: skip_dns}

templates/var/lib/ansible/group_vars/OSv3.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ ansible_ssh_user: {{ssh_user}}
66
ansible_sudo: true
77
ansible_become: true
88
deployment_type: {{deployment_type}} # deployment type valid values are origin, online and openshif-enterprise
9-
osm_default_subdomain: cloudapps.{{domainname}} # default subdomain to use for exposed routes
9+
openshift_master_default_subdomain: {{app_subdomain}} # default subdomain to use for exposed routes
1010
openshift_override_hostname_check: true
1111
openshift_use_openshift_sdn: {{openshift_use_openshift_sdn}}
1212
openshift_use_flannel: {{openshift_use_flannel}}

0 commit comments

Comments
 (0)