-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathDockerfile.ci
24 lines (19 loc) · 914 Bytes
/
Dockerfile.ci
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
# Usage sample :
#
# docker build --build-arg WEEK=`date +%Y%U` -t chouette-core-iev-build -f Dockerfile.ci .
# PGDATABASE="chouette_core_iev_build_`date +%s`"
# mkdir -p cache/maven
# docker run -v $PWD/cache/maven:/root/.m2 --add-host "db:172.17.0.1" -e PGDATABASE=$PGDATABASE -it --rm chouette-core-iev-build
# dropdb $PGDATABASE
FROM maven:3.6.0-jdk-8
ARG WEEK
ENV LANG=en_US.UTF-8 LANGUAGE=en_US:en LC_ALL=en_US.UTF-8
# maven image are not uptodate .. with openjdk-8-jdk .. dist-upgrade is required
RUN apt-get update && apt-get dist-upgrade -y && \
apt-get install -y --no-install-recommends locales postgresql-client-common postgresql-client-9.6 git-core && \
localedef -i en_US -c -f UTF-8 en_US.UTF-8
WORKDIR /usr/src/mymaven
COPY . ./
ENV PGHOST="db" PGDATABASE="chouette" PGUSER="chouette" PGPASSWORD="chouette"
ENV MAVEN_OPTS="-Dfile.encoding=UTF-8"
CMD ["sh", "./docker-ci.sh"]