Skip to content

Commit

Permalink
Merge pull request #809 from VirtualFlyBrain/alpha-sync-1b2e
Browse files Browse the repository at this point in the history
sync: alpha  with alpha-sync-1b2e
  • Loading branch information
Robbie1977 authored Nov 24, 2020
2 parents f7bb60f + c9075c4 commit 294f122
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 4 deletions.
2 changes: 2 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ ARG targetBranch=development
ARG originBranch=development
ARG defaultBranch=development

VOLUME /tmp/error

#SET TAG/BRANCH to use:
ARG geppettoRelease=vfb_20200604_a
ARG geppettoModelRelease=vfb_20200604_a
Expand Down
14 changes: 10 additions & 4 deletions dockerFiles/startup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ then
# Frontend final build
cd $HOME/workspace/org.geppetto.frontend
/bin/echo -e "\e[96mMaven install org.geppetto.frontend\e[0m"
mvn ${mvnOpt} -DcontextPath=org.geppetto.frontend -DuseSsl=false install
mvn ${mvnOpt} -DcontextPath=org.geppetto.frontend -DuseSsl=false install
rm -rf src
fi

Expand All @@ -51,10 +51,11 @@ then
echo "Client SOLR Server: $SOLR_SERVER"
echo "Google Analytics code: ${googleAnalyticsSiteCode}"
echo "useSSL:${USESSL}"

# Start a logfile
mkdir -p $SERVER_HOME/serviceability/logs
echo 'Start of log...' > $SERVER_HOME/serviceability/logs/log.log
export log="$SERVER_HOME/serviceability/logs/log.log"
echo 'Start of log...' > $log

# Deploy Geppetto
rm $SERVER_HOME/./repository/usr/* || true
Expand All @@ -69,7 +70,12 @@ then
sed 's@ErrorFile="$KERNEL_HOME/serviceability/error.log"@ErrorFile="$SERVER_HOME/serviceability/logs/log.log"@g' -i $SERVER_HOME/bin/dmk.sh

# output log
tail -F --retry $SERVER_HOME/serviceability/logs/log.log || true &
tail -F --retry "$log" || true &

# check for any memory issues:
pid=1
match="java.lang.OutOfMemoryError"
while sleep 60; do if fgrep --quiet "$match" "$log"; then cp -fv "$log" "/tmp/error/$(date '+%Y-%m-%d_%H-%M').log" ; kill $pid; exit 0; fi; done &

# start virgo server
$SERVER_HOME/bin/startup.sh
Expand Down

0 comments on commit 294f122

Please sign in to comment.