개발/Python
selenium + jupyter lab+python3 환경구성하기
cozynow
2020. 3. 10. 02:30
부제목 : 호스트와 시간 맞추기
FROM selenium/standalone-chrome
USER root
RUN wget https://bootstrap.pypa.io/get-pip.py
RUN apt-get update -y
RUN apt-get dist-upgrade -y
RUN apt-get autoremove
RUN apt-get install -y python3 vim python3-pip curl wget python3.8-venv language-pack-ko
RUN pip3 install --upgrade pip
RUN python3 get-pip.py
RUN python3 -m pip install selenium django pyautogui
RUN pip3 install jupyterlab tensorflow && \
jupyter serverextension enable --py jupyterlab --sys-prefix
EXPOSE 7777
EXPOSE 7770
WORKDIR /home/seluser/workspace
CMD ["jupyter", "lab", "--ip=0.0.0.0", "--allow-root"]
Dockerfile bulid $ run
docker build . -t selenium-chrome-lab3
docker run --name selenium-python31 \
-v /etc/localtime:/etc/localtime:ro \
-e "TZ=Asia/Seoul" -v \
"$PWD":/home/seluser/workspace -w /home/seluser/workspace \
-p 7777:7777 -p 7770:7770 -d selenium-chrome-lab3