fixing SDC logback mounting defect 03/18803/3
authorMandeep Khinda <mandeep.khinda@amdocs.com>
Fri, 13 Oct 2017 17:54:20 +0000 (17:54 +0000)
committerMandeep Khinda <mandeep.khinda@amdocs.com>
Fri, 13 Oct 2017 18:04:59 +0000 (18:04 +0000)
sdc-be now starts and robot passes healthcheck

----------------------------------------
Basic ASDC Health Check         | PASS |
----------------------------------------

Note that I did not verify whether the logging
function is working - priority for this issue
is to get SDC running.

Issue-ID: OOM-359

Change-Id: Ic810109878aa003c54350a6e70a4aeeea9b2f0ea
Signed-off-by: Mandeep Khinda <mandeep.khinda@amdocs.com>
kubernetes/sdc/templates/sdc-be.yaml

index 29f029f..0ba4db5 100644 (file)
@@ -86,8 +86,12 @@ spec:
           name: sdc-logs
         - mountPath: /var/log/onap
           name: sdc-logs-2
-        - mountPath: /var/lib/jetty/config/catalog-be/logback.xml
+        - mountPath: /tmp/logback.xml
           name: sdc-logback
+        lifecycle:
+          postStart:
+            exec:
+              command: ["/bin/sh", "-c", "export LOG=wait_logback.log; touch $LOG; export SRC=/tmp/logback.xml; export DST=/var/lib/jetty/config/catalog-be/; while [ ! -e $DST ]; do echo 'Waiting for $DST...' >> $LOG; sleep 5; done; sleep 2; /bin/cp -f $SRC $DST; echo 'Done' >> $LOG"]
         ports:
         - containerPort: 8443
         - containerPort: 8080