aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xdocker-build.sh19
1 files changed, 11 insertions, 8 deletions
diff --git a/docker-build.sh b/docker-build.sh
index 8b6df1d..c1b7f9f 100755
--- a/docker-build.sh
+++ b/docker-build.sh
@@ -52,18 +52,21 @@ gunzip -c ${AR} | tar xvf - -C ${APP_DIR} --strip-components=1
cat <<EOF > "${DCM_DIR}/start-manager.sh"
#!/bin/bash
-MAIN='org.openecomp.dcae.controller.service.standardeventcollector.servers.manager.DcaeControllerServiceStandardeventcollectorManagerServer'
-ACTION='start'
+MAIN=org.openecomp.dcae.controller.service.standardeventcollector.servers.manager.DcaeControllerServiceStandardeventcollectorManagerServer
+ACTION=start
-WORKDIR='/opt/app/manager'
-LOGS="${WORKDIR}/logs"
+WORKDIR=/opt/app/manager
-[ ! -d "$LOGS" ] && mkdir -p "$LOGS"
+LOGS=\$WORKDIR/logs
-echo 10.0.4.102 $(hostname).dcae.simpledemo.openecomp.org >> /etc/hosts
+mkdir -p \$LOGS
+
+cd \$WORKDIR
+
+echo 10.0.4.102 \$(hostname).dcae.simpledemo.openecomp.org >> /etc/hosts
+
+exec java -cp ./config:./lib:./lib/*:./bin \$MAIN \$ACTION > logs/manager.out 2>logs/manager.err
-exec java -cp ./config:./lib:./lib/*:./bin "${MAIN}" "${ACTION}" \
- > logs/manager.out 2>logs/manager.err
EOF
chmod 775 "${DCM_DIR}/start-manager.sh"