forked from projectatomic/commissaire
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Dockerfile
39 lines (35 loc) · 1.38 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
FROM fedora:25
MAINTAINER Red Hat, Inc. <[email protected]>
# Install required dependencies and commissaire
RUN dnf -y update && dnf -y install --setopt=tsflags=nodocs openssh-clients redhat-rpm-config python3-pip python3-virtualenv git gcc libffi-devel openssl-devel etcd redis; dnf clean all && \
git clone https://github.com/projectatomic/commissaire-service.git && \
git clone https://github.com/projectatomic/commissaire-http.git && \
virtualenv-3 /environment && \
. /environment/bin/activate && \
cd commissaire-service && \
pip install -U pip && \
pip install -r requirements.txt && \
pip install . && \
cd ../commissaire-http && \
pip install -r requirements.txt && \
pip install . && \
cd .. && \
pip freeze > /installed-python-deps.txt && \
dnf remove -y gcc git redhat-rpm-config libffi-devel && \
dnf clean all && \
sed -i 's|dir /var/lib/redis|dir /data/redis|g' /etc/redis.conf && \
mkdir -p /etc/commissaire /data/{redis,etcd}
# Copy the all-in-one start script
COPY tools/startup-all-in-one.sh /commissaire/
# Copy the etcd init script
COPY tools/etcd_init.sh /commissaire/
# Configuration directory. Use --volume=/path/to/your/configs:/etc/commissaire
VOLUME /etc/commissaire/
# Directory for data
VOLUME /data
# commissaire-server address
EXPOSE 8000
# Run everything from /commissaire
WORKDIR /commissaire
# Execute the all-in-one-script
CMD /commissaire/startup-all-in-one.sh