-
Notifications
You must be signed in to change notification settings - Fork 7
/
Dockerfile
54 lines (41 loc) · 1.92 KB
/
Dockerfile
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
51
52
53
54
#=================================================================================================
# Project: CADS/MADS - An Integrated Web-based Visual Platform for Materials Informatics
# Hokkaido University (2018)
# Last Update: Q3 2023
# ________________________________________________________________________________________________
# Authors: Mikael Nicander Kuwahara (Lead Developer) [2021-]
# Jun Fujima (Former Lead Developer) [2018-2021]
# ________________________________________________________________________________________________
# Description: Dockerfile for running CADS via Docker
#=================================================================================================
#-------------------------------------------------------------------------------------------------
FROM python:3.9
ENV PYTHONUNBUFFERED 1
RUN mkdir -p /usr/src/app
WORKDIR /usr/src/app
RUN apt-get update && apt-get install -y apt-transport-https
RUN sh -c 'curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | apt-key add -' \
&& sh -c 'echo "deb https://dl.yarnpkg.com/debian/ stable main" | tee /etc/apt/sources.list.d/yarn.list' \
&& sh -c 'curl -sL https://deb.nodesource.com/setup_14.x | bash -'
# sudo apt-get install -y nodejs
RUN apt-get update && apt-get install -y \
postgresql-client \
yarn \
# s3cmd=1.1.* \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*
RUN pip install pip --upgrade \
&& pip install pipenv
COPY ./Pipfile /usr/src/app/
COPY ./Pipfile.lock /usr/src/app/
RUN pipenv install --deploy --system \
&& rm -rf ~/.cache/pipenv
COPY ./package.json /usr/src/app/
COPY ./yarn.lock /usr/src/app/
RUN yarn install --ignore-engines --frozen-lockfile
COPY . /usr/src/app/
RUN yarn run build
# CMD sh bin/start-app.sh
EXPOSE 8000
# CMD gunicorn madsapp.wsgi --limit-request-line 8188 --log-file -
#-------------------------------------------------------------------------------------------------