Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 16 additions & 2 deletions ansible/roles/showroom/tasks/60-showroom-verify.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,25 @@

- name: Compute port suffix when non-standard port is used
ansible.builtin.set_fact:
f_port_suffix: "{% if (showroom_primary_port | default(443) | int) != 443 %}:{{ showroom_primary_port }}{% endif %}"
f_port_suffix: >-
{% if (showroom_primary_port | default(443) | int) not in [443, 80] -%}
:{{ showroom_primary_port }}
{%- endif %}

- name: Compute URL scheme
ansible.builtin.set_fact:
f_url_scheme: >-
{% if (showroom_primary_port | default(443) | int) == 80 -%}
http
{%- else -%}
https
{%- endif %}

- name: Capture lab_ui_url as fact
ansible.builtin.set_fact:
f_lab_ui_url: "https://{{ showroom_host }}{{ f_port_suffix | default('') }}/{{ showroom_primary_path }}"
f_lab_ui_url: >-
{{ f_url_scheme }}://{{ showroom_host -}}
{{ f_port_suffix | default('') }}/{{ showroom_primary_path }}

- name: Output showroom view(s) URLs as userinfo and userdata
agnosticd_user_info:
Expand Down
2 changes: 1 addition & 1 deletion ansible/roles/showroom/templates/index.html.j2
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
{% elif showroom_tab_services | length > 0 %}
<div class="content">
<div class="split left">
<iframe id="doc" src="./{{ showroom_component_name }}/"index.html" width="100%" style="border:none;"></iframe>
<iframe id="doc" src="./{{ showroom_component_name }}/index.html" width="100%" style="border:none;"></iframe>
</div>
<div class="split right">
<div class="tab">
Expand Down
Loading