forked from OpenBudget/budgetkey-data-pipelines
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
30 lines (24 loc) · 1017 Bytes
/
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
FROM frictionlessdata/datapackage-pipelines:latest
ADD ./ /
ADD dpp-runners.yaml /budgetkey_data_pipelines/pipelines/
RUN apk add --update libxml2 libxslt sudo openssh-client curl
RUN addgroup dpp && adduser -s /bin/bash -D -G dpp dpp && addgroup dpp root && addgroup dpp redis && \
mkdir -p /var/datapackages && chown dpp.dpp /var/datapackages -R && \
mkdir -p /home/dpp/.ssh && chown dpp.dpp /home/dpp/.ssh -R && \
chown dpp.dpp /var/log/redis -R && \
chown dpp.dpp /var/lib/redis -R && \
chown dpp.dpp /var/run/redis -R && \
chmod 700 /home/dpp/.ssh && \
chown dpp.dpp /budgetkey_data_pipelines -R && \
echo '%root ALL=(ALL) NOPASSWD: ALL' > /etc/sudoers.d/root
USER dpp
RUN cat /etc/sudoers
RUN sudo pip install -r /requirements.txt && sudo pip install -e /
ENV PYTHONPATH=/
ENV DPP_PROCESSOR_PATH=/budgetkey_data_pipelines/processors
ENV DPP_REDIS_HOST=localhost
ENV REDIS_USER=dpp
ENV REDIS_GROUP=dpp
WORKDIR /budgetkey_data_pipelines/pipelines/
EXPOSE 5000
CMD ["server"]