added filebeat to all components
[oom.git] / kubernetes / policy / templates / dep-pap.yaml
index 0ee1b12..aeb3d6b 100644 (file)
@@ -95,7 +95,7 @@ spec:
         lifecycle:
           postStart:
             exec:
-              command: ["/bin/sh", "-c", "sleep 60; cp -f /tmp/logback.xml /opt/app/policy/servers/pap/webapps/pap/WEB-INF/classes/logback.xml;cp -f /tmp/policy-install/logback.xml /opt/app/policy/servers/console/webapps/ecomp/WEB-INF/classes/logback.xml"]
+              command: ["/bin/sh", "-c", "export LOG=wait_logback.log; touch $LOG; export SRC=/tmp/logback.xml; export DST=/opt/app/policy/servers/pap/webapps/pap/WEB-INF/classes/; while [ ! -e $DST ]; do echo 'Waiting for $DST...' >> $LOG; sleep 5; done; sleep 2; /bin/cp -f $SRC $DST; export SRC=/tmp/policy-install/logback.xml; export DST=/opt/app/policy/servers/console/webapps/onap/WEB-INF/classes/; while [ ! -e $DST ]; do echo 'Waiting for $DST...' >> $LOG; sleep 5; done; sleep 2; /bin/cp -f $SRC $DST; echo 'Done' >> $LOG"]
       - image: {{ .Values.image.filebeat }}
         imagePullPolicy: {{ .Values.pullPolicy }}
         name: filebeat-onap