-
Notifications
You must be signed in to change notification settings - Fork 32
/
Dockerfile
56 lines (42 loc) · 1.71 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
51
52
53
54
55
56
# SPDX-FileCopyrightText: 2022 Albert Meroño, Rinke Hoekstra, Carlos Martínez
#
# SPDX-License-Identifier: MIT
FROM python:3.11-slim
MAINTAINER [email protected]
# Default values for env variables
ARG GRLC_GITHUB_ACCESS_TOKEN=
ARG GRLC_GITLAB_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_GITLAB_ACCESS_TOKEN=$GRLC_GITLAB_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 python3-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 npm
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"]