aboutsummaryrefslogtreecommitdiffstats
path: root/deliveries/src/main/scripts
diff options
context:
space:
mode:
authorIttay Stern <ittay.stern@att.com>2019-12-19 16:26:17 +0200
committerIttay Stern <ittay.stern@att.com>2019-12-19 16:26:17 +0200
commit9dff984184ad33fb12d006ee564d4269ae07248e (patch)
tree8db513feeb13cbaf340c4bdd14edf2327005b60a /deliveries/src/main/scripts
parentfecb7b8df6d8f589fd879b41731e7495cf657c92 (diff)
Make logback.xml editable after VID is deployed
Issue-ID: VID-733 Change-Id: I16b9fa0e4f310900aa7bd733e40c00868db33f90 Signed-off-by: Ittay Stern <ittay.stern@att.com>
Diffstat (limited to 'deliveries/src/main/scripts')
-rwxr-xr-xdeliveries/src/main/scripts/localize.sh10
1 files changed, 9 insertions, 1 deletions
diff --git a/deliveries/src/main/scripts/localize.sh b/deliveries/src/main/scripts/localize.sh
index 918027913..d149e3bae 100755
--- a/deliveries/src/main/scripts/localize.sh
+++ b/deliveries/src/main/scripts/localize.sh
@@ -7,6 +7,12 @@ fillTemplateProperties() {
}
}
+createWritableLogbackConfig() {
+ # Create logback.xml in /tmp/vid/
+ # /tmp/logback.xml is owned by root and unmodifiable
+ cp -f /tmp/logback.xml /tmp/vid/logback.xml
+}
+
deployWarOnTomcatManually() {
cd /usr/local/tomcat/webapps/
mkdir vid
@@ -14,6 +20,8 @@ deployWarOnTomcatManually() {
jar -xf /tmp/vid/stage/vid.war
}
+
+createWritableLogbackConfig
deployWarOnTomcatManually
TEMPLATES_BASE_DIR=/usr/local/tomcat/webapps/vid/WEB-INF
@@ -22,7 +30,7 @@ fillTemplateProperties ${TEMPLATES_BASE_DIR}
# Set CATALINA_OPTS if not defined previously
# Enables late-evaluation of env variables, such as VID_KEYSTORE_PASSWORD
-: "${CATALINA_OPTS:=-Dvid.keystore.password=${VID_KEYSTORE_PASSWORD} -Dvid.keyalias=vid@vid.onap.org -Dvid.keystore.filename=${VID_KEYSTORE_FILENAME} -Dcom.att.eelf.logging.file=logback.xml -Dcom.att.eelf.logging.path=/tmp}"
+: "${CATALINA_OPTS:=-Dvid.keystore.password=${VID_KEYSTORE_PASSWORD} -Dvid.keyalias=vid@vid.onap.org -Dvid.keystore.filename=${VID_KEYSTORE_FILENAME} -Dcom.att.eelf.logging.file=logback.xml -Dcom.att.eelf.logging.path=/tmp/vid/}"
echo "CATALINA_OPTS: ${CATALINA_OPTS}"
export CATALINA_OPTS