|
13 | 13 | # See the License for the specific language governing permissions and |
14 | 14 | # limitations under the License. |
15 | 15 |
|
16 | | -FROM parisson/docker:v0.4 |
| 16 | +FROM debian:jessie |
17 | 17 |
|
18 | 18 | MAINTAINER Guillaume Pellerin < [email protected]>, Thomas fillon < [email protected]> |
19 | 19 |
|
20 | 20 | RUN mkdir -p /srv/app |
21 | 21 | RUN mkdir -p /srv/src |
22 | 22 | RUN mkdir -p /srv/src/timeside |
23 | | -WORKDIR /srv/src/timeside |
| 23 | + |
| 24 | +WORKDIR /srv/src |
24 | 25 |
|
25 | 26 | # install confs, keys and deps |
26 | | -COPY debian-requirements.txt /srv/src/timeside/ |
| 27 | +RUN apt-get update && apt-get install -y apt-transport-https |
| 28 | +COPY debian-requirements.txt /srv/src/ |
27 | 29 | RUN apt-get update && \ |
28 | 30 | DEBIAN_PACKAGES=$(egrep -v "^\s*(#|$)" debian-requirements.txt) && \ |
29 | 31 | apt-get install -y --force-yes $DEBIAN_PACKAGES && \ |
30 | 32 | apt-get clean |
31 | 33 |
|
32 | | -# Install binary dependencies with conda |
33 | | -COPY environment-pinned.yml /srv/src/timeside/ |
34 | | -RUN conda update conda &&\ |
35 | | - conda config --append channels conda-forge --append channels thomasfillon --append channels soumith &&\ |
36 | | - conda env update --name root --file environment-pinned.yml &&\ |
37 | | - pip install -U --force-reinstall functools32 &&\ |
| 34 | +# Install conda in /opt/miniconda |
| 35 | +ENV PATH /opt/miniconda/bin:$PATH |
| 36 | +RUN wget https://repo.continuum.io/miniconda/Miniconda2-latest-Linux-x86_64.sh -O miniconda.sh && \ |
| 37 | + /bin/bash miniconda.sh -b -p /opt/miniconda && \ |
| 38 | + rm miniconda.sh && \ |
| 39 | + hash -r && \ |
| 40 | + ln -s /opt/miniconda/etc/profile.d/conda.sh /etc/profile.d/conda.sh && \ |
| 41 | + echo ". /opt/miniconda/etc/profile.d/conda.sh" >> ~/.bashrc && \ |
| 42 | + echo "conda activate" >> ~/.bashrc && \ |
| 43 | + conda config --set always_yes yes --set changeps1 yes |
| 44 | + |
| 45 | +COPY environment-pinned.yml /srv/src/ |
| 46 | +RUN conda config --append channels conda-forge --append channels thomasfillon --append channels soumith &&\ |
| 47 | + conda env update --file environment-pinned.yml &&\ |
38 | 48 | conda clean --all --yes |
39 | 49 |
|
40 | 50 | # Link glib-networking with Conda to fix missing TLS/SSL support in Conda Glib library |
41 | | -RUN rm /opt/miniconda/lib/libgio* &&\ |
42 | | - ln -s /usr/lib/x86_64-linux-gnu/libgio* /opt/miniconda/lib/ |
43 | | - |
44 | | -COPY . /srv/src/timeside/ |
| 51 | +#RUN rm /opt/miniconda/lib/libgio* &&\ |
| 52 | +# ln -s /usr/lib/x86_64-linux-gnu/libgio* /opt/miniconda/lib/ |
45 | 53 |
|
46 | 54 | ENV PYTHON_EGG_CACHE=/srv/.python-eggs |
47 | 55 | RUN mkdir -p $PYTHON_EGG_CACHE && \ |
48 | 56 | chown www-data:www-data $PYTHON_EGG_CACHE |
49 | 57 |
|
50 | | -# Install TimeSide |
51 | | -RUN pip install -e . |
52 | | - |
53 | | -# Install Timeside plugins from ./lib |
54 | | -COPY ./app/bin/setup_plugins.sh /srv/app/bin/setup_plugins.sh |
55 | | -COPY ./lib/ /srv/src/plugins/ |
56 | | -RUN /bin/bash /srv/app/bin/setup_plugins.sh |
| 58 | +RUN mkdir -p /srv/src/plugins |
| 59 | +COPY ./lib/plugins/ /srv/src/plugins/ |
57 | 60 |
|
58 | | -# Install Vamp plugins |
59 | | -COPY ./app/bin/install_vamp_plugins.sh /srv/app/bin/install_vamp_plugins.sh |
| 61 | +RUN mkdir -p /srv/app/bin |
| 62 | +COPY ./app/bin/ /srv/app/bin/ |
| 63 | +RUN python /srv/app/bin/link_gstreamer.py |
| 64 | +#RUN /bin/bash /srv/app/bin/setup_plugins.sh |
60 | 65 | RUN /bin/bash /srv/app/bin/install_vamp_plugins.sh |
61 | 66 |
|
| 67 | +# Install timeside |
| 68 | +WORKDIR /srv/src/timeside |
| 69 | +COPY . /srv/src/timeside/ |
| 70 | +RUN pip install -e . |
| 71 | + |
| 72 | +# Install bower |
| 73 | +RUN npm install -g bower |
| 74 | + |
62 | 75 | WORKDIR /srv/app |
63 | 76 | EXPOSE 8000 |
0 commit comments