Skip to content

Commit

Permalink
[add] python, npm, nvm, pyenv, tox + serverless
Browse files Browse the repository at this point in the history
  • Loading branch information
ChipWolf committed Nov 7, 2018
1 parent fe589fd commit 79029f6
Show file tree
Hide file tree
Showing 2 changed files with 33 additions and 3 deletions.
34 changes: 32 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,12 @@ ENV HOME /root
ENV LANG en_US.UTF-8
ENV TERM xterm-256color

RUN apt-get update \
&& apt-get install -y zsh git tmux vim curl sudo exuberant-ctags
RUN apt-get update && \
apt-get install -y \
zsh git tmux vim curl sudo exuberant-ctags make build-essential \
libssl-dev zlib1g-dev libbz2-dev libreadline-dev libsqlite3-dev \
wget curl llvm libncurses5-dev libncursesw5-dev xz-utils libffi-dev \
liblzma-dev gnupg

ENV USER chip
ENV DIRPATH /home/$USER
Expand All @@ -29,5 +33,31 @@ RUN $DIRPATH/.etc/link.sh/link.sh -u $DIRPATH/.etc/.link.conf -b \
&& rm -rf $DIRPATH/.etc.bak
COPY 00-bullettrain.zsh $DIRPATH/.zsh/zsh-os-conf/local-pre/00-bullettrain.zsh

RUN curl -sL https://deb.nodesource.com/setup_11.x | sudo -E bash - \
&& sudo apt-get install -y nodejs

RUN curl -sL https://raw.githubusercontent.com/creationix/nvm/v0.33.11/install.sh | sudo -E bash -

RUN git clone git://github.com/yyuu/pyenv.git $DIRPATH/.pyenv \
&& git clone https://github.com/yyuu/pyenv-virtualenv.git $DIRPATH/.pyenv/plugins/pyenv-virtualenv \
&& echo "eval \"\$(pyenv init -)\"" >> $DIRPATH/.zshrc \
&& echo "eval \"\$(pyenv virtualenv-init -)\"" >> $DIRPATH/.zshrc

ENV PYENV_ROOT $DIRPATH/.pyenv
ENV PATH $PYENV_ROOT/shims:$PYENV_ROOT/bin:$PATH

RUN sudo apt-get install -y libssl-dev

RUN pyenv install 2.7.15 \
&& pyenv install 3.7.1 \
&& pyenv install pypy2.7-6.0.0 \
&& pyenv install pypy3.5-6.0.0

RUN pyenv global 3.7.1
RUN pip install -U pip tox

RUN sudo npm install -g try-thread-sleep \
&& sudo npm install -g serverless --ignore-scripts spawn-sync

CMD ["zsh"]

2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1 +1 @@
[![Docker Automated build](https://img.shields.io/docker/automated/cwlf/env.svg)](https://hub.docker.com/r/cwlf/env)
[![Docker Automated build](https://img.shields.io/docker/build/cwlf/env.svg)](https://hub.docker.com/r/cwlf/env)

0 comments on commit 79029f6

Please sign in to comment.