forked from CLARIAH/grlc
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
50 lines (37 loc) · 1.51 KB
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
FROM python:3.6.8
MAINTAINER albert.merono@vu.nl
# Default values for env variables
ARG GRLC_GITHUB_ACCESS_TOKEN=
ARG GRLC_SERVER_NAME=grlc.io
ARG GRLC_SPARQL_ENDPOINT=http://dbpedia.org/sparql
ENV GRLC_GITHUB_ACCESS_TOKEN=$GRLC_GITHUB_ACCESS_TOKEN \
GRLC_SERVER_NAME=$GRLC_SERVER_NAME \
GRLC_SPARQL_ENDPOINT=$GRLC_SPARQL_ENDPOINT
ENV GRLC_USER="grlc" \
GRLC_HOME="/home/grlc" \
GRLC_LOG_DIR="/var/log/grlc" \
GITLAB_VERSION=8.10.4 \
GRLC_CACHE_DIR="/etc/docker-grlc"
ENV GRLC_INSTALL_DIR="${GRLC_HOME}/grlc" \
GRLC_DATA_DIR="${GRLC_HOME}/data" \
GRLC_BUILD_DIR="${GRLC_CACHE_DIR}/build" \
GRLC_RUNTIME_DIR="${GRLC_CACHE_DIR}/runtime"
RUN apt-get update \
&& DEBIAN_FRONTEND=noninteractive apt-get install -y nginx git-core logrotate python-pip locales gettext-base sudo build-essential apt-utils \
&& update-locale LANG=C.UTF-8 LC_MESSAGES=POSIX \
&& locale-gen en_US.UTF-8 \
&& DEBIAN_FRONTEND=noninteractive dpkg-reconfigure locales \
&& rm -rf /var/lib/apt/lists/*
RUN curl -sL https://deb.nodesource.com/setup_10.x | sudo -E bash -
RUN apt-get update && apt-get install -y nodejs
COPY ./ ${GRLC_INSTALL_DIR}
COPY docker-assets/assets/build/ ${GRLC_BUILD_DIR}/
RUN bash ${GRLC_BUILD_DIR}/install.sh
COPY docker-assets/assets/runtime/ ${GRLC_RUNTIME_DIR}/
COPY docker-assets/entrypoint.sh /sbin/entrypoint.sh
RUN chmod 755 /sbin/entrypoint.sh
EXPOSE 80/tcp
VOLUME ["${GRLC_DATA_DIR}", "${GRLC_LOG_DIR}"]
WORKDIR ${GRLC_INSTALL_DIR}
ENTRYPOINT ["/sbin/entrypoint.sh"]
CMD ["app:start"]