Last active
February 13, 2020 16:32
-
-
Save NotFounds/db2db4a7bb80b08476925d023df4cb7c to your computer and use it in GitHub Desktop.
nvidia-docker
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM nvidia/cuda:10.0-cudnn7-runtime | |
RUN apt-get update && apt-get install -y \ | |
gcc \ | |
make \ | |
openssl \ | |
libssl-dev \ | |
libbz2-dev \ | |
zlib1g-dev \ | |
libreadline-dev \ | |
libsqlite3-dev \ | |
bzip2 \ | |
git \ | |
language-pack-ja-base \ | |
language-pack-ja \ | |
sudo \ | |
wget \ | |
vim | |
RUN git clone https://github.com/yyuu/pyenv.git /pyenv | |
RUN git clone https://github.com/yyuu/pyenv-virtualenv.git \ | |
/pyenv/plugins/pyenv-virtualenv | |
RUN \ | |
echo 'export PYENV_ROOT="/pyenv"' >> ~/.bashrc && \ | |
echo 'export PATH="$PYENV_ROOT/bin:$PATH"' >> ~/.bashrc && \ | |
echo 'eval "$(pyenv init -)"' >> ~/.bashrc && \ | |
echo 'eval "$(pyenv virtualenv-init -)"' >> ~/.bashrc | |
RUN \ | |
. ~/.bashrc && \ | |
pyenv install 3.6.8 && \ | |
pyenv global 3.6.8 | |
RUN \ | |
. ~/.bashrc && \ | |
pyenv global 3.6.8 && \ | |
pip install --upgrade pip && \ | |
pip install --upgrade setuptools && \ | |
pip install jupyter matplotlib tensorflow-gpu==2.0.0-beta1 sentencepiece | |
COPY entrypoint.sh /entrypoint.sh | |
ENTRYPOINT ["/entrypoint.sh"] | |
CMD [] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /bin/bash -e | |
echo 'function status_face() {' >> ~/.bashrc && \ | |
echo ' if [ $? -eq 0 ]; then' >> ~/.bashrc && \ | |
echo ' echo "\[\e[32;47m\]^_^\[\e[0m\]"' >> ~/.bashrc && \ | |
echo ' else' >> ~/.bashrc && \ | |
echo ' echo "\[\e[41;47m\]x_x\[\e[0m\]"' >> ~/.bashrc && \ | |
echo ' fi' >> ~/.bashrc && \ | |
echo '}' >> ~/.bashrc && \ | |
echo 'export PS1="\[\e[30;43m\]\u\[\e[30;46m\]\w\\[\e[0m\] $ "' >> ~/.bashrc && \ | |
echo 'export LANG="ja_JP.UTF-8"' >> ~/.bashrc && \ | |
exec $@ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment