Do not set the protocol and port to https until when https://support.d4science.org/issues/13024 if fixed and the new dataminer deployed

This commit is contained in:
Andrea Dell'Amico 2018-12-14 17:08:15 +01:00
parent 5eac7a8c1f
commit db534612f0
1 changed files with 3 additions and 2 deletions

View File

@ -12,10 +12,11 @@ sed -Ei 's/hostname=\".*\"\ hostport/hostname="{{ smartgears_hostname }}" hostpo
# Set the port. It is different from the tomcat one if there is a reverse proxy before the service.
# https has the precedence if it is available
# TODO: change back to http and https_port when https://support.d4science.org/issues/13024 if fixed and the new dataminer deployed
{% if setup_nginx %}
{% if https_port is defined %}
sed -Ei 's/hostport=\".*\"\ includeDataInputsInResponse/hostport="{{ https_port }}" includeDataInputsInResponse/' "$WPS_CONFIG_FILE"
sed -Ei 's/protocol=\".*\"\ hostname/protocol="https" hostname/' "$WPS_CONFIG_FILE"
sed -Ei 's/hostport=\".*\"\ includeDataInputsInResponse/hostport="{{ http_port | default('80') }}" includeDataInputsInResponse/' "$WPS_CONFIG_FILE"
sed -Ei 's/protocol=\".*\"\ hostname/protocol="http" hostname/' "$WPS_CONFIG_FILE"
{% else %}
sed -Ei 's/hostport=\".*\"\ includeDataInputsInResponse/hostport="{{ http_port | default('80') }}" includeDataInputsInResponse/' "$WPS_CONFIG_FILE"
{% endif %}