-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile.base
50 lines (43 loc) · 1.53 KB
/
Dockerfile.base
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
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
# Base Image
FROM ubuntu:16.04
MAINTAINER [email protected]
# APT package 설치
RUN apt-get -y update
RUN apt-get -y dist-upgrade
RUN apt-get install -y \
# pip, git, vim
python-pip \
git \
vim \
# pyenv build problem solve
make build-essential \
libssl-dev zlib1g-dev libbz2-dev \
libreadline-dev libsqlite3-dev wget \
curl llvm libncurses5-dev libncursesw5-dev \
xz-utils tk-dev \
# zsh
zsh \
# nginx
nginx \
# supervisor
supervisor
# pyenv 설치
RUN curl -L https://raw.githubusercontent.com/pyenv/pyenv-installer/master/bin/pyenv-installer | bash
ENV PATH=/root/.pyenv/bin:$PATH
RUN pyenv install 3.6.2
# zsh(oh-my-zsh theme) 설치
RUN wget https://github.com/robbyrussell/oh-my-zsh/raw/master/tools/install.sh -O - | zsh || true
RUN chsh -s /usr/bin/zsh
# pyenv settings
RUN echo 'export PATH="/root/.pyenv/bin:$PATH"' >> ~/.zshrc
RUN echo 'eval "$(pyenv init -)"' >> ~/.zshrc
RUN echo 'eval "$(pyenv virtualenv-init -)"' >> ~/.zshrc
# pyenv virtualenv
RUN pyenv virtualenv 3.6.2 app
# uWGSI install
RUN /root/.pyenv/versions/app/bin/pip install uwsgi
# requirements 설치
ENV LANG C.UTF-8
COPY requirements.txt /srv/requirements.txt
RUN /root/.pyenv/versions/app/bin/pip install -r \
/srv/requirements.txt