forked from fengxia41103/mouse
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile-simba
59 lines (46 loc) · 1.47 KB
/
Dockerfile-simba
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
FROM continuumio/miniconda3
# name your environment and choose python 3.x version
ARG conda_env=simba
# Install system packages
RUN apt-get --allow-releaseinfo-change update && \
apt-get update && \
apt-get install -y \
build-essential \
libnss3-tools \
libx11-xcb-dev \
libxss1 \
libxcomposite-dev \
libatk1.0-0 \
libgtk2.0-0 \
libxcomposite1 \
graphviz \
ffmpeg \
x11-xserver-utils
RUN mkdir /app
WORKDIR /app
# Make RUN commands use `bash --login`:
SHELL ["/bin/bash", "--login", "-c"]
# Create the environment:
COPY env-simba.yml .
RUN conda env create -f env-simba.yml
# Initialize conda in bash config fiiles:
RUN conda init bash
# Activate the environment, and make sure it's activated:
RUN echo "conda init bash" >> ~/.bashrc
RUN echo "conda activate simba" >> ~/.bashrc
RUN echo "Make sure conda python3.6 is installed:"
# Make RUN commands use the new environment:
SHELL ["conda", "run", "-n", "simba", "/bin/bash", "-c"]
# Upgrade pip
RUN pip install --upgrade pip
RUN conda update -n base -c defaults conda
RUN conda install -c anaconda wxpython
RUN pip install simba-uw-no-tf
RUN conda install -c conda-forge shapely
RUN conda install tensorflow
ADD requirements.txt /app/
RUN pip install --no-cache-dir -r requirements.txt
# prepend conda environment to path
ENV PATH $CONDA_DIR/envs/${conda_env}/bin:$PATH
# if you want this environment to be the default one, uncomment the following line:
ENV CONDA_DEFAULT_ENV ${conda_env}