Skip to content

Commit

Permalink
[test] Fix missing cli scripts
Browse files Browse the repository at this point in the history
  • Loading branch information
chbrandt committed Mar 23, 2021
1 parent 09d30d5 commit df620a3
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 30 deletions.
49 changes: 19 additions & 30 deletions dockerfile/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,20 @@
FROM continuumio/miniconda3
FROM ubuntu
MAINTAINER "Carlos Brandt <carloshenriquebrandt gmail"

RUN conda update -y conda
RUN DEBIAN_FRONTEND='noninteractive' \
apt-get update \
&& apt-get install -y python3-pip \
git-core \
vim \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*

RUN python3 -m pip install ipython \
jupyterlab \
matplotlib \
numpy \
pandas \
scipy

ARG WORKDIR="/work"
ARG DOCKER_USERNAME="user"
Expand Down Expand Up @@ -30,31 +43,7 @@ WORKDIR "$WORKDIR"

VOLUME "$WORKDIR/volume"

# Managing envs is done with conda
RUN conda create -n "$DOCKER_USERNAME" \
-c conda-forge \
-y python=3.8 pip jupyterlab \
&& conda init bash

# # Install EADA
# RUN pip install https://github.com/chbrandt/eada/archive/refs/tags/v1.0a2.tar.gz
#
# ENV JUPYTER_ENABLE_LAB="yes"
# ENTRYPOINT ["conda", "activate", "$DOCKER_USERNAME"]
# CMD ["jupyter-lab", "--allow-root", "--no-browser", "--ip", "0.0.0.0"]
# ENTRYPOINT ["conda", "run", "-n", "user", "jupyter-lab", "--allow-root", "--no-browser", "--ip", "0.0.0.0"]

RUN echo "#!/bin/bash" \
> /tmp/run.sh \
# && echo "conda init bash && conda activate user" \
# >> /tmp/run.sh \
&& echo "jupyter-lab --allow-root --no-browser --ip=0.0.0.0 &> /dev/stdout" \
>> /tmp/run.sh \
&& chmod +x /tmp/run.sh
# ENTRYPOINT exec /tmp/run.sh
ENTRYPOINT ["/bin/bash","-c","conda run --live-stream -n user /tmp/run.sh"]
# ENTRYPOINT exec conda run -n user /tmp/run.sh & tail -f /tmp/run.log

# ENTRYPOINT exec conda run -n user conda env list
# ENTRYPOINT exec conda run -n user jupyter-lab --allow-root --no-browser --ip=0.0.0.0
# CMD [ "--allow-root","--no-browser","--ip","0.0.0.0" ]
# Install EADA
RUN pip3 install https://github.com/chbrandt/eada/archive/refs/tags/v1.0a2.tar.gz

CMD ["jupyter-lab", "--allow-root", "--no-browser", "--ip", "0.0.0.0"]
1 change: 1 addition & 0 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@

##########

import os
import sys
from setuptools import setup, find_packages

Expand Down

0 comments on commit df620a3

Please sign in to comment.