Browse Source

Upgrade Dockerfile to use requirements.txt and clean up some packages

master
Ricardo Branco 6 years ago
parent
commit
5db6353e8c
1 changed files with 16 additions and 2 deletions
  1. 16
    2
      Dockerfile

+ 16
- 2
Dockerfile View File

@@ -1,8 +1,22 @@
1 1
 FROM	registry:2
2 2
 
3
-RUN	apk --no-cache add python3 python3-dev
3
+COPY	requirements.txt /tmp
4 4
 
5
-RUN	pip3 install --no-cache-dir docker docker[tls] pyyaml
5
+RUN	apk --no-cache add \
6
+		gcc \
7
+		libc-dev \
8
+		libffi-dev \
9
+		openssl-dev \
10
+		python3-dev \
11
+		python3 && \
12
+	pip3 install --no-cache-dir --upgrade pip && \
13
+	pip3 install --no-cache-dir -r /tmp/requirements.txt && \
14
+	apk del \
15
+		gcc \
16
+		libc-dev \
17
+		libffi-dev \
18
+		openssl-dev \
19
+		python3-dev
6 20
 
7 21
 COPY	clean_registry.py /usr/local/bin/clean_registry.py
8 22
 

Loading…
Cancel
Save