forked from pymc-devs/pymc
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
30 lines (22 loc) · 856 Bytes
/
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
FROM jupyter/base-notebook:python-3.9.12
LABEL name="pymc"
LABEL description="Environment for PyMC version 4"
ENV LANG=C.UTF-8 LC_ALL=C.UTF-8
# Switch to jovyan to avoid container runs as root
USER $NB_UID
COPY /conda-envs/environment-dev.yml .
RUN mamba env create -f environment-dev.yml && \
/bin/bash -c ". activate pymc-dev && \
mamba install -c conda-forge -y pymc" && \
conda clean --all -f -y
# Fix PkgResourcesDeprecationWarning
RUN pip install --upgrade --user setuptools==58.3.0
#Setup working folder
WORKDIR /home/jovyan/work
# For running from bash
SHELL ["/bin/bash","-c"]
RUN echo "conda activate pymc-dev" >> ~/.bashrc && \
source ~/.bashrc
# For running from jupyter notebook
EXPOSE 8888
CMD ["conda", "run", "--no-capture-output", "-n", "pymc-dev", "jupyter","notebook","--ip=0.0.0.0","--port=8888","--no-browser"]