-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathDockerfile.venv
61 lines (54 loc) · 2.04 KB
/
Dockerfile.venv
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
# Create docker image from python:3.9-buster
# This image serves as the base compile image
############### COMPILE IMAGE ###############
FROM python:3.9-buster AS venv
WORKDIR /LedFx
RUN apt-get update && apt-get install -y --no-install-recommends \
gcc=4:8.3.0-1 \
git=1:2.20.1-2+deb10u3 \
libatlas3-base=3.10.3-8 \
zlib1g-dev=1:1.2.11.dfsg-1 \
portaudio19-dev=19.6.0-1+deb10u1 \
python3-dev=3.7.3-1 \
\
# Pillow dependencies for dev branch
libfreetype6-dev=2.9.1-3+deb10u2 \
libfribidi-dev=1.0.5-3.1+deb10u1 \
libharfbuzz-dev=2.3.1-1 \
libjpeg-turbo-progs=1:1.5.2-2+deb10u1 \
libjpeg62-turbo-dev=1:1.5.2-2+deb10u1 \
liblcms2-dev=2.9-3 \
libopenjp2-7-dev=2.3.0-2+deb10u2 \
tcl8.6-dev=8.6.9+dfsg-2 \
tk8.6-dev=8.6.9-2 \
libtiff5-dev=4.1.0+git191117-2~deb10u2 \
\
# aubio dependencies
python3-aubio=0.4.6-2 \
python-aubio=0.4.6-2 \
aubio-tools=0.4.6-2 \
libavcodec-dev=7:4.1.6-1~deb10u1 \
libavformat-dev=7:4.1.6-1~deb10u1 \
libavutil-dev=7:4.1.6-1~deb10u1 \
libswresample-dev=7:4.1.6-1~deb10u1 \
libavresample-dev=7:4.1.6-1~deb10u1 \
libsndfile1-dev=1.0.28-6 \
librubberband-dev=1.8.1-7 \
libsamplerate0-dev=0.1.9-2 \
&& rm -fr \
/var/{cache,log}/* \
/var/lib/apt/lists/* \
&& python -m venv /LedFx/venv \
&& /LedFx/venv/bin/pip install --no-cache-dir --upgrade pip wheel setuptools numpy \
&& /LedFx/venv/bin/pip install --no-cache-dir --upgrade aubio
# Set /LedFx/venv/bin to $PATH
ENV PATH="/LedFx/venv/bin:$PATH"
# Copy LedFx requirements from Github
RUN wget -q -O /LedFx/requirements.txt https://raw.githubusercontent.com/LedFx/LedFx/dev/requirements.txt
#Install LedFx requirements build the wheel's and delete test *.pyc *.pyo files from venv for smaller final image
RUN /LedFx/venv/bin/pip install --no-cache-dir -r requirements.txt \
&& find /LedFx/venv \
\( -type d -a -name test -o -name tests \) \
-o \( -type f -a -name '*.pyc' -o -name '*.pyo' \) \
-exec rm -rf '{}' \+
CMD ["/bin/bash"]