Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
V
vlkb-siav2
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
ViaLactea
vlkb-siav2
Commits
606bec20
Commit
606bec20
authored
5 months ago
by
Robert Butora
Browse files
Options
Downloads
Patches
Plain Diff
docker: places webapp last in docker-build and set -eux for start-siav2.sh
parent
a1f4e78b
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
docker/Dockerfile
+18
-12
18 additions, 12 deletions
docker/Dockerfile
docker/start-siav2.sh
+2
-3
2 additions, 3 deletions
docker/start-siav2.sh
with
20 additions
and
15 deletions
docker/Dockerfile
+
18
−
12
View file @
606bec20
...
...
@@ -17,13 +17,6 @@ ENV HOME /root
RUN
apt-get
-y
update
\
&&
apt-get
-y
install
apt-utils unzip
ENV
WEBAPP_DIR=/webapps/vlkb-siav2
RUN
mkdir
-p
${
WEBAPP_DIR
}
ARG
VLKB_VERSION
COPY
vlkb-siav2-${VLKB_VERSION}.war ${WEBAPP_DIR}/
RUN
cd
${
WEBAPP_DIR
}
&&
unzip vlkb-siav2-
${
VLKB_VERSION
}
.war
# Tomcat must load postgresql DB driver, vlkb-siav2 does not explicitely load it
COPY
deps/postgresql-*.jar ${CATALINA_BASE}/lib/
...
...
@@ -37,17 +30,30 @@ COPY deps/setenv.sh ${CATALINA_BASE}/bin/
WORKDIR
${CATALINA_BASE}
RUN
chmod
-R
a+rwX conf
# enable config at start-up
RUN
chmod
a+rw
${
WEBAPP_DIR
}
/WEB-INF/web.xml
\
&&
chmod
a+rw
${
WEBAPP_DIR
}
/WEB-INF/classes/search.properties
\
&&
chmod
a+rw
${
WEBAPP_DIR
}
/WEB-INF/classes/formatresponsefilter.properties
# set default
env
DISCOVERY_CONTEXT_ROOT=datasets
# configure during start-up
COPY
start-siav2.sh /root
# create empty to be able to volume-bind at start-up
ENV
STARTUP_LOG=/tmp/start-siav2.log
RUN
echo
" "
>
${
STARTUP_LOG
}
# install webapp
ENV
WEBAPP_DIR=/webapps/vlkb-siav2
RUN
mkdir
-p
${
WEBAPP_DIR
}
ARG
VLKB_VERSION
COPY
vlkb-siav2-${VLKB_VERSION}.war ${WEBAPP_DIR}/
RUN
cd
${
WEBAPP_DIR
}
&&
unzip vlkb-siav2-
${
VLKB_VERSION
}
.war
# enable config at start-up
RUN
chmod
a+rw
${
WEBAPP_DIR
}
/WEB-INF/web.xml
\
&&
chmod
a+rw
${
WEBAPP_DIR
}
/WEB-INF/classes/search.properties
\
&&
chmod
a+rw
${
WEBAPP_DIR
}
/WEB-INF/classes/formatresponsefilter.properties
# run
RUN
chmod
+rx /root
&&
chmod
+rx /root/start-siav2.sh
...
...
This diff is collapsed.
Click to expand it.
docker/start-siav2.sh
+
2
−
3
View file @
606bec20
#!/bin/bash
set
+e
set
-eux
{
date
whoami
env
# configure CONTEXT_ROOT
...
...
@@ -38,7 +37,7 @@ sed -i "s/.*DbObstap\.level.*=.*/DbObstap.level = $DBG_LEVEL/g" $CATALINA_BASE/c
###################################################################
date
}
1>
/tmp/start-siav2.log 2>&1
}
1>
$STARTUP_LOG
$CATALINA_HOME
/bin/catalina.sh run
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment