Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/maven/fixes/8.0' into maven/rele…
Browse files Browse the repository at this point in the history
…ase/8.0
  • Loading branch information
metaventis-build committed Nov 27, 2023
2 parents 9263b50 + 96b47e9 commit 5c17861
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -114,9 +114,6 @@
# --- relative login path from external authentication service
# REPOSITORY_SERVICE_AUTH_EXTERNAL_LOGIN=/shibboleth

# --- relative logout path from external authentication service
# REPOSITORY_SERVICE_AUTH_EXTERNAL_LOGOUT=/logout

# --- absolut path from external authentication provider
# REPOSITORY_SERVICE_HOME_AUTH_EXTERNAL_LOGIN_PROVIDERS_URL=

Expand Down Expand Up @@ -198,9 +195,6 @@
# --- time after a session expires in seconds
# REPOSITORY_SERVICE_HTTP_SERVER_SESSION_TIMEOUT=60

# --- enables transformer (e.g. previews for office files)
# REPOSITORY_SERVICE_TRANSFORM_ENABLED=true


########################################################################################################################
### services-rendering-database
Expand Down Expand Up @@ -234,6 +228,9 @@
# --- use dynamic url
# SERVICES_RENDERING_SERVICE_DYNAMIC_URL=false

# --- custom content url
# SERVICES_RENDERING_SERVICE_CUSTOM_CONTENT_URL=

# --- enables general data protection regulation
# SERVICES_RENDERING_SERVICE_GDPR_ENABLED=false

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,15 @@ my_port_external="${SERVICES_RENDERING_SERVICE_PORT_EXTERNAL:-9100}"
my_path_external="${SERVICES_RENDERING_SERVICE_PATH_EXTERNAL:-/esrender}"
my_base_external="${my_prot_external}://${my_host_external}:${my_port_external}${my_path_external}"


# used to configure dynamic domains based on the accessing domains
# used to configure dynamic domains based on the accessing domains

rendering_service_custom_content_url="${SERVICES_RENDERING_SERVICE_CUSTOM_CONTENT_URL:-}"
rendering_service_dynamic_url="${SERVICES_RENDERING_SERVICE_DYNAMIC_URL:-false}"

my_external_url="${my_base_external}"
if [[ "$rendering_service_dynamic_url" == "true" ]]; then
my_external_url="${my_prot_external}://'.\$_SERVER['HTTP_X_FORWARDED_HOST'] ? \$_SERVER['HTTP_X_FORWARDED_HOST'] : \$_SERVER['HTTP_HOST'].':${my_port_external}${my_path_external}"
my_external_url="${my_prot_external}://'.(\$_SERVER['HTTP_X_FORWARDED_HOST'] ? \$_SERVER['HTTP_X_FORWARDED_HOST'] : \$_SERVER['HTTP_HOST']).':${my_port_external}${my_path_external}"
fi

my_prot_internal="${SERVICES_RENDERING_SERVICE_PROT_INTERNAL:-http}"
Expand Down Expand Up @@ -282,6 +284,11 @@ systemConf="${RS_ROOT}/conf/system.conf.php"
sed -i -r 's|\$MC_URL = ['"'"'"].*|\$MC_URL = '"'${my_external_url}'"';|' "${systemConf}"
sed -i -r 's|\$MC_DOCROOT.*|\$MC_DOCROOT = "'"${RS_ROOT}"'";|' "${systemConf}"
sed -i -r 's|\$CC_RENDER_PATH.*|\$CC_RENDER_PATH = "'"${RS_CACHE}/data"'";|' "${systemConf}"
sed -i -r 's|\$CUSTOM_CONTENT_URL =.*|\$CUSTOM_CONTENT_URL = '"'${rendering_service_custom_content_url}'"';|' "${systemConf}"
grep -q '$CUSTOM_CONTENT_URL' "${systemConf}" || echo '$CUSTOM_CONTENT_URL = '"'${rendering_service_custom_content_url}'"';' >> "${systemConf}"




[[ -n $my_gdpr_modules ]] && my_gdpr_modules="'${my_gdpr_modules//,/','}'"
sed -i -r 's|\$DATAPROTECTIONREGULATION_CONFIG.*|\$DATAPROTECTIONREGULATION_CONFIG = ["enabled" => '"${my_gdpr_enabled}"', "modules" => ['"${my_gdpr_modules}"'], "urls" => ['"${my_gdpr_urls}"']];|' "${systemConf}"
Expand Down Expand Up @@ -326,6 +333,7 @@ if [[ -n $my_plugins ]] ; then
fi

homeApp="${RS_ROOT}/conf/esmain/homeApplication.properties.xml"

xmlstarlet ed -L \
-u '/properties/entry[@key="scheme"]' -v "${my_prot_internal}" \
-u '/properties/entry[@key="host"]' -v "${my_host_internal}" \
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ services:
SERVICES_RENDERING_SERVICE_PATH_EXTERNAL: "${SERVICES_RENDERING_SERVICE_PATH:-/esrender}"
SERVICES_RENDERING_SERVICE_PORT_INTERNAL: "8080"
SERVICES_RENDERING_SERVICE_DYNAMIC_URL: "${SERVICES_RENDERING_SERVICE_DYNAMIC_URL:-false}"
SERVICES_RENDERING_SERVICE_CUSTOM_CONTENT_URL: "${SERVICES_RENDERING_SERVICE_CUSTOM_CONTENT_URL:-}"
SERVICES_RENDERING_SERVICE_PROXY_NONPROXYHOSTS: "${NON_PROXY_HOST:-}"
SERVICES_RENDERING_SERVICE_PROXY_HOST: "${PROXY_HOST:-}"
SERVICES_RENDERING_SERVICE_PROXY_PORT: "${PROXY_PORT:-}"
Expand Down

0 comments on commit 5c17861

Please sign in to comment.