# HG changeset patch # User smith@nwoca.org # Date 1515695571 0 # Node ID 7441285bf3260df13dd32eef7368884852fce59a # Parent d5f4087419e6a7a2eed83e294df133d07f386b7f# Parent 55b4143fd39ef69098700d94f87b2d451025d175 flow: Merged 'v2.0.1' to ('production'). diff -r d5f4087419e6 -r 7441285bf326 prod/import-usas.sh --- a/prod/import-usas.sh Wed Jan 10 01:45:28 2018 +0000 +++ b/prod/import-usas.sh Thu Jan 11 18:32:51 2018 +0000 @@ -1,23 +1,23 @@ -#!/bin/bash - -source "$( dirname "${BASH_SOURCE[0]}")/../scripts/.functions.sh" - -docker-compose stop usasapp usasdb -resetDbVolume usasdb -docker-compose rm -vf usasapp usasdb - -export IMP_IRN=${IMP_IRN} -export IMP_URL=${IMP_URL-ftp://username:password@nwoca.org} -export IMP_PATH=${IMP_PATH} - -[ -f "docker-compose.override.yml" ] && export OVERRIDE=" -f docker-compose.override.yml" - [ -f "docker-compose.usasimport.override.yml" ] && export OVERRIDE2=" -f docker-compose.usasimport.override.yml" -# -docker-compose -f docker-compose.yml -f ${SSDT_HOME}/prod/import-usas.yml $OVERRIDE rm -f usasimport -# start import and wait for completion - docker-compose -f docker-compose.yml -f ${SSDT_HOME}/prod/import-usas.yml $OVERRIDE $OVERRIDE2 up usasimport | tee usasimport.log -# remove temporary container -docker-compose -f docker-compose.yml -f ${SSDT_HOME}/prod/import-usas.yml $OVERRIDE rm -f usasimport -# start application -docker-compose up -d usasapp - +#!/bin/bash + +source "$( dirname "${BASH_SOURCE[0]}")/../scripts/.functions.sh" + +docker-compose stop usasapp usasdb +resetDbVolume usasdb +docker-compose rm -vf usasapp usasdb + +export IMP_IRN=${IMP_IRN} +export IMP_URL=${IMP_URL-ftp://username:password@nwoca.org} +export IMP_PATH=${IMP_PATH} + +[ -f "docker-compose.override.yml" ] && export OVERRIDE=" -f docker-compose.override.yml" + [ -f "docker-compose.usasimport.override.yml" ] && export OVERRIDE2=" -f docker-compose.usasimport.override.yml" +# +docker-compose -f docker-compose.yml -f ${SSDT_HOME}/prod/import-usas.yml $OVERRIDE rm -f usasimport +# start import and wait for completion + docker-compose -f docker-compose.yml -f ${SSDT_HOME}/prod/import-usas.yml $OVERRIDE $OVERRIDE2 up usasimport | tee usasimport.log +# remove temporary container +docker-compose -f docker-compose.yml -f ${SSDT_HOME}/prod/import-usas.yml $OVERRIDE rm -f usasimport +# start application +docker-compose up -d usasapp + diff -r d5f4087419e6 -r 7441285bf326 prod/usps-services.yml --- a/prod/usps-services.yml Wed Jan 10 01:45:28 2018 +0000 +++ b/prod/usps-services.yml Thu Jan 11 18:32:51 2018 +0000 @@ -1,34 +1,34 @@ - uspsdb: - restart: unless-stopped - image: docker.ssdt.io/ssdt-postgres:5 - volumes: - - uspsdata:/var/lib/postgresql/data - networks: - - default - environment: - - DB_NAME=uspsdb - - DB_USER=usps - - DB_PASS=${USPS_DB_PASSWORD:-uspsdefault} - uspsapp: - restart: unless-stopped - image: docker.ssdt.io/usps-app:${USPS_TAG:-prod} - depends_on: - - uspsdb - networks: - default: - aliases: - - ${USPS_APP_HOST:-uspsapp-svr} - environment: - - DB_HOST=uspsdb - - DB_NAME=uspsdb - - DB_USER=usps - - DB_PASS=${USPS_DB_PASSWORD:-uspsdefault} - - DB_POOL_LEAKDETECTIONTHRESHOLD=300000 - - USPS_MODULE_USASINTEGRATION_CONFIGURATION_USASCONFIGURATION_CLIENTHOST=${USAS_APP_HOST:-usasapp-svr} - - USPS_MODULE_USASINTEGRATION_CONFIGURATION_USASCONFIGURATION_CLIENTDNSLOOKUP=true - - USPS_MODULE_USASINTEGRATION_CONFIGURATION_USASCONFIGURATION_SERVERHOST=0.0.0.0 - - USPS_MODULE_USASINTEGRATION_CONFIGURATION_USASCONFIGURATION_SERVERHOSTDNSLOOKUP=false - - USPS_MODULE_USASINTEGRATION_CONFIGURATION_USASCONFIGURATION_APPLICATIONID=${USPS_APPLICATIONID:- } - - USPS_MODULE_USASINTEGRATION_CONFIGURATION_USASCONFIGURATION_APIKEY=${USPS_APIKEY:- } - - USPS_MODULE_USASINTEGRATION_CONFIGURATION_USASCONFIGURATION_REMOTEAPPLICATIONID=${USAS_APPLICATIONID:- } - - USPS_MODULE_USASINTEGRATION_CONFIGURATION_USASCONFIGURATION_REMOTEAPIKEY=${USAS_APIKEY:- } + uspsdb: + restart: unless-stopped + image: docker.ssdt.io/ssdt-postgres:5 + volumes: + - uspsdata:/var/lib/postgresql/data + networks: + - default + environment: + - DB_NAME=uspsdb + - DB_USER=usps + - DB_PASS=${USPS_DB_PASSWORD:-uspsdefault} + uspsapp: + restart: unless-stopped + image: docker.ssdt.io/usps-app:${USPS_TAG:-prod} + depends_on: + - uspsdb + networks: + default: + aliases: + - ${USPS_APP_HOST:-uspsapp-svr} + environment: + - DB_HOST=uspsdb + - DB_NAME=uspsdb + - DB_USER=usps + - DB_PASS=${USPS_DB_PASSWORD:-uspsdefault} + - DB_POOL_LEAKDETECTIONTHRESHOLD=300000 + - USPS_MODULE_USASINTEGRATION_CONFIGURATION_USASCONFIGURATION_CLIENTHOST=${USAS_APP_HOST:-usasapp-svr} + - USPS_MODULE_USASINTEGRATION_CONFIGURATION_USASCONFIGURATION_CLIENTDNSLOOKUP=true + - USPS_MODULE_USASINTEGRATION_CONFIGURATION_USASCONFIGURATION_SERVERHOST=0.0.0.0 + - USPS_MODULE_USASINTEGRATION_CONFIGURATION_USASCONFIGURATION_SERVERHOSTDNSLOOKUP=false + - USPS_MODULE_USASINTEGRATION_CONFIGURATION_USASCONFIGURATION_APPLICATIONID=${USPS_APPLICATIONID:- } + - USPS_MODULE_USASINTEGRATION_CONFIGURATION_USASCONFIGURATION_APIKEY=${USPS_APIKEY:- } + - USPS_MODULE_USASINTEGRATION_CONFIGURATION_USASCONFIGURATION_REMOTEAPPLICATIONID=${USAS_APPLICATIONID:- } + - USPS_MODULE_USASINTEGRATION_CONFIGURATION_USASCONFIGURATION_REMOTEAPIKEY=${USAS_APIKEY:- }