100% open-source IoT Platform - Integrate your devices, add intelligence, build custom apps
Java asset-managementbuildingdashboarddataplatformdevice-managementedge-computingenergyenergy-managementenergy-monitorfleet-managementfleet-telematicsiotiot-applicationiot-platformmodbusmqttmqtt-brokerota-updaterules-enginesmartcity
Minor proxy updates
Rich Turner6cc1d76f959c
diff --git a/profile/deploy.yml b/profile/deploy.ymlindex 28fd75285..641a01543 100644--- a/profile/deploy.yml+++ b/profile/deploy.yml@@ -29,6 +29,9 @@ services:# Bearer tokens are only valid for minutes, and authentication fails if Keycloak drifts.TZ: Europe/Zurich+ # File to which std out will be logged+ LOGFILE: /var/log/proxy.log+# The public host name of this OpenRemote installation. Set this to request/manage an SSL# certificate with the free https://letsencrypt.org/ provider. The default 'localhost' will# rely on a baked-in self-signed certificate. If you change this, adjust manager#IDENTITY_NETWORK_HOST.diff --git a/proxy/entrypoint.sh b/proxy/entrypoint.shindex fb9f64ab6..20ffeb4cc 100644--- a/proxy/entrypoint.sh+++ b/proxy/entrypoint.sh@@ -218,11 +218,11 @@ function auto_renew {renew ${domains}if [ $? -ne 0 ]then- log_error "failed to renew certificate for ${subject}!"+ log_error "failed to renew certificate for ${DOMAINNAME}!"exitcode=1elserenewed_certs+=("$subject")- log_info "renewed certificate for ${subject}"+ log_info "renewed certificate for ${DOMAINNAME}"fielselog_info "Certificate for ${DOMAINNAME} does not require renewal."@@ -301,19 +301,18 @@ function remove {function log_error {if [ -n "${LOGFILE}" ]then- if [[ "$@" ]]; then echo "[ERROR][`date +'%Y-%m-%d %T'`] $@\n" >> ${LOGFILE};+ if [[ "$@" ]]; then echo "[ERROR][`date +'%Y-%m-%d %T'`] $@" >> ${LOGFILE};else echo; fi>&2 echo "[ERROR][`date +'%Y-%m-%d %T'`] $@"elseecho "[ERROR][`date +'%Y-%m-%d %T'`] $@"fi-}function log_info {if [ -n "${LOGFILE}" ]then- if [[ "$@" ]]; then echo "[INFO][`date +'%Y-%m-%d %T'`] $@\n" >> ${LOGFILE};+ if [[ "$@" ]]; then echo "[INFO][`date +'%Y-%m-%d %T'`] $@" >> ${LOGFILE};else echo; fi>&2 echo "[INFO][`date +'%Y-%m-%d %T'`] $@"else@@ -366,7 +365,7 @@ function cron_auto_renewal {# If not defined, the default is dailyCRON_TIME=${CRON_TIME:-@daily}log_info "Scheduling cron job with execution time ${CRON_TIME}"- echo "${CRON_TIME} root /entrypoint.sh auto-renew >> /var/log/cron.log 2>&1" > /etc/cron.d/letsencrypt+ echo "${CRON_TIME} root /entrypoint.sh auto-renew >> ${LOGFILE} 2>&1" > /etc/cron.d/letsencrypt# Start crondservice cron start@@ -382,6 +381,7 @@ log_info "LE_CERT_ROOT: ${LE_CERT_ROOT}"log_info "LE_ARCHIVE_ROOT: ${LE_ARCHIVE_ROOT}"log_info "LE_RENEWAL_CONFIG_ROOT: ${LE_RENEWAL_CONFIG_ROOT}"log_info "LE_CMD: ${LE_CMD}"+log_info "LOGFILE: ${LOGFILE}"if [ $# -eq 0 ]then