-
Notifications
You must be signed in to change notification settings - Fork 65
/
Dockerfile
76 lines (65 loc) · 1.6 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
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
FROM phusion/baseimage:0.11
ENV ENVIRONMENT DEV
ENV LOG_LEVEL INFO
ENV LANG en_US.UTF-8
ENV LC_ALL en_US.UTF-8
ENV PIPENV_VENV_IN_PROJECT 1
ARG SOURCE_COMMIT
ENV SOURCE_COMMIT ${SOURCE_COMMIT}
ARG SCHEMA_HASH
ENV SCHEMA_HASH adb5cd9b
#ENV SCHEMA_HASH ${SCHEMA_HASH}
ARG DOCKER_TAG
ENV DOCKER_TAG ${DOCKER_TAG}
ENV APP_ROOT /app
ENV WSGI_APP ${APP_ROOT}/hive/server/serve.py
ENV HTTP_SERVER_PORT 8080
RUN \
apt-get update && \
apt-get install -y \
awscli \
build-essential \
daemontools \
libffi-dev \
libmysqlclient-dev \
libssl-dev \
make \
liblz4-tool \
postgresql \
postgresql-contrib \
python3 \
python3-dev \
python3-pip \
libxml2-dev \
libxslt-dev \
runit \
s3cmd \
libpcre3 \
libpcre3-dev
RUN \
pip3 install --upgrade pip setuptools
ADD . /app
WORKDIR /app
ADD scripts/entrypoint.sh /usr/local/bin/entrypoint.sh
ADD scripts/hivesync.sh /usr/local/bin/hivesync.sh
ADD scripts/hivesynccontinue.sh /usr/local/bin/hivesynccontinue.sh
RUN chmod +x /usr/local/bin/entrypoint.sh
RUN chmod +x /usr/local/bin/hivesync.sh
RUN chmod +x /usr/local/bin/hivesynccontinue.sh
RUN \
pip3 install . && \
apt-get remove -y \
build-essential \
libffi-dev \
libssl-dev && \
apt-get autoremove -y && \
rm -rf \
/root/.cache \
/var/lib/apt/lists/* \
/tmp/* \
/var/tmp/* \
/var/cache/* \
/usr/include \
/usr/local/include
EXPOSE ${HTTP_SERVER_PORT}
CMD /usr/local/bin/entrypoint.sh