Skip to content

Commit

Permalink
Have *_url variables be URLs instead of hostnames
Browse files Browse the repository at this point in the history
  • Loading branch information
ajkyffin committed Sep 12, 2023
1 parent 838e6fa commit a796e0e
Show file tree
Hide file tree
Showing 8 changed files with 27 additions and 28 deletions.
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -184,11 +184,11 @@ Create a playbook file to hold the list of roles you wish to install and any var
icat_server_authn_list: "db ldap"
icat_server_authn_ldap_admin: "false"
icat_server_lucene_populateBlockSize: "10000"
authn_db_url: "{{ ansible_fqdn }}"
authn_anon_url: "{{ ansible_fqdn }}"
authn_ldap_url: "{{ ansible_fqdn }}"
lucene_url: "{{ ansible_fqdn }}"
icat_url: "{{ ansible_fqdn }}"
authn_db_url: "https://{{ ansible_fqdn }}:8181"
authn_anon_url: "https://{{ ansible_fqdn }}:8181"
authn_ldap_url: "https://{{ ansible_fqdn }}:8181"
lucene_url: "https://{{ ansible_fqdn }}:8181"
icat_url: "https://{{ ansible_fqdn }}:8181"


- role: 'dev_common'
Expand Down
14 changes: 7 additions & 7 deletions group_vars/all/vars.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,25 +32,25 @@ authn_reader_password: "{{ vault_authn_reader_password }}"
authn_icatuser_password: "{{ vault_authn_icatuser_password }}"

# Authn_simple server URL
authn_simple_url: "{{ ansible_fqdn }}"
authn_simple_url: "https://{{ ansible_fqdn }}:8181"

# Authn_db server URL
authn_db_url: "{{ ansible_fqdn }}"
authn_db_url: "https://{{ ansible_fqdn }}:8181"

# Authn_anon server URL
authn_anon_url: "{{ ansible_fqdn }}"
authn_anon_url: "https://{{ ansible_fqdn }}:8181"

# Authn_ldap server URL
authn_ldap_url: "{{ ansible_fqdn }}"
authn_ldap_url: "https://{{ ansible_fqdn }}:8181"

# ICAT Lucene server URL
lucene_url: "{{ ansible_fqdn }}"
lucene_url: "https://{{ ansible_fqdn }}:8181"

# ICAT server URL
icat_url: "{{ ansible_fqdn }}"
icat_url: "https://{{ ansible_fqdn }}:8181"

# IDS server URL
ids_url: "{{ ansible_fqdn }}"
ids_url: "https://{{ ansible_fqdn }}:8181"

# DataGateway Download API database hostname, database name, username and password
db_topcat_hostname: "localhost"
Expand Down
2 changes: 1 addition & 1 deletion roles/authn_ip_clf/templates/authn_ip_clf.properties.j2
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ ip.readall.account = agcr
ip.public.account = public

# hostname (and port if not default) of the ICAT that this authenticator is used on
icat.server.url = https://{{ icat_url }}:8181
icat.server.url = {{ icat_url }}
# login details for an account on the ICAT that has read all access
icat.authn_ip.login = simple username authn_ip password authnip14

Expand Down
7 changes: 3 additions & 4 deletions roles/datagateway_download_api/templates/run.properties.j2
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@

facility.list = LILS

facility.LILS.icatUrl = https://{{ icat_url }}:8181
facility.LILS.idsUrl = https://{{ ids_url }}:8181
facility.LILS.icatUrl = {{ icat_url }}
facility.LILS.idsUrl = {{ ids_url }}

# Download transport URLs
# topcat.json can specify one or more download transport types for each facility, egs "https", "globus";
Expand All @@ -19,8 +19,7 @@ facility.LILS.idsUrl = https://{{ ids_url }}:8181
# internal http URL.
# If the property is not defined, Topcat will use the facility's idsUrl by default.

facility.LILS.downloadType.http = http://{{ ids_url }}:8080
facility.LILS.downloadType.https = https://{{ ids_url }}:8181
facility.LILS.downloadType.https = {{ ids_url }}

# enable send email
mail.enable = false
Expand Down
4 changes: 2 additions & 2 deletions roles/dev_common/templates/settings.xml.j2
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@
<activeByDefault>true</activeByDefault>
</activation>
<properties>
<serverUrl>https://{{ icat_url }}:8181</serverUrl>
<serverUrl>{{ icat_url }}</serverUrl>
{% if lucene_url is defined and lucene_url %}
<luceneUrl>https://{{ lucene_url }}:8181</luceneUrl>
<luceneUrl>{{ lucene_url }}</luceneUrl>
{% endif %}
<javax.net.ssl.trustStore>{{ payara_domain_dir }}/config/cacerts.jks</javax.net.ssl.trustStore>
<containerHome>{{ payara_dir }}</containerHome>
Expand Down
10 changes: 5 additions & 5 deletions roles/icat_server/templates/run.properties.j2
Original file line number Diff line number Diff line change
Expand Up @@ -23,15 +23,15 @@ authn.list = {{ icat_server_authn_list }}

# Parameters for each of the four plugins
{% if ansible_local.local.instantiations.authn_db is defined and ansible_local.local.instantiations.authn_db == 'true' %}
authn.db.url = https://{{ authn_db_url }}:8181
authn.db.url = {{ authn_db_url }}
authn.db.friendly = DB
authn.db.admin = {{ icat_server_authn_db_admin }}
{% else %}
!authn.db.url = https://localhost:8181
{% endif %}

{% if ansible_local.local.instantiations.authn_ldap is defined and ansible_local.local.instantiations.authn_ldap == 'true' %}
authn.ldap.url = https://{{ authn_ldap_url }}:8181
authn.ldap.url = {{ authn_ldap_url }}
authn.ldap.admin = {{ icat_server_authn_ldap_admin }}
authn.ldap.friendly = Federal Id
{% else %}
Expand All @@ -41,15 +41,15 @@ authn.ldap.friendly = Federal Id
{% endif %}

{% if ansible_local.local.instantiations.authn_simple is defined and ansible_local.local.instantiations.authn_simple == 'true' %}
authn.simple.url = https://{{ authn_simple_url }}:8181
authn.simple.url = {{ authn_simple_url }}
authn.simple.friendly = Simple
{% else %}
!authn.simple.url = https://localhost:8181
!authn.simple.friendly = Simple
{% endif %}

{% if ansible_local.local.instantiations.authn_anon is defined and ansible_local.local.instantiations.authn_anon == 'true' %}
authn.anon.url = https://{{ authn_anon_url }}:8181
authn.anon.url = {{ authn_anon_url }}
authn.anon.friendly = Anonymous
{% else %}
!authn.anon.url = https://localhost:8181
Expand All @@ -76,7 +76,7 @@ log.list = SESSION WRITE READ INFO

# Lucene
{% if ansible_local.local.instantiations.icat_lucene is defined and ansible_local.local.instantiations.icat_lucene == 'true' %}
lucene.url = https://{{ lucene_url }}:8181
lucene.url = {{ lucene_url }}
lucene.populateBlockSize = {{ icat_server_lucene_populateBlockSize }}
lucene.directory = /home/{{ payara_user }}/{{ icat_lucene_data_dir }}
lucene.backlogHandlerIntervalSeconds = 60
Expand Down
6 changes: 3 additions & 3 deletions roles/icat_server_dev/templates/run.properties.j2
Original file line number Diff line number Diff line change
Expand Up @@ -7,16 +7,16 @@ importCacheSize = 50
exportCacheSize = 50
authn.list = db simple

authn.db.url = https://{{ authn_db_url }}:8181
authn.simple.url = https://{{ authn_simple_url }}:8181
authn.db.url = {{ authn_db_url }}
authn.simple.url = {{ authn_simple_url }}

notification.list = Dataset Datafile
notification.Dataset = CU
notification.Datafile = CU

log.list = SESSION WRITE READ INFO

lucene.url = https://{{ lucene_url }}:8181
lucene.url = {{ lucene_url }}
lucene.populateBlockSize = 10000
lucene.directory = ${HOME}/data/lucene
lucene.backlogHandlerIntervalSeconds = 60
Expand Down
2 changes: 1 addition & 1 deletion roles/ids_server/templates/run.properties.j2
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# General properties
icat.url = https://{{ icat_url }}:8181
icat.url = {{ icat_url }}

plugin.zipMapper.class = org.icatproject.ids.storage.ZipMapper

Expand Down

0 comments on commit a796e0e

Please sign in to comment.