-
Notifications
You must be signed in to change notification settings - Fork 1
/
Dockerfile
41 lines (29 loc) · 926 Bytes
/
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
FROM debian:jessie
MAINTAINER theplatypus <nicolas.bloyet@see-d.fr>
USER root
# ---- install node and npm
RUN \
apt-get update && \
apt-get install -y apt-utils gnupg curl wget && \
apt-get install -y libssl-dev libsasl2-dev
# install node & npm from apt
RUN apt-get -qq update
RUN apt-get install -y nodejs npm
# update to the latest stable node forever
RUN npm install -g n &&\
n stable
# debian installs `node` as `nodejs`
RUN update-alternatives --install /usr/bin/node node /usr/bin/nodejs 10
# ---- install R:latest from CRAN repos
RUN /bin/echo "deb http://cran.rstudio.com/bin/linux/debian jessie-cran3/" >> /etc/apt/sources.list
RUN \
apt-get update && \
apt-get install -y --force-yes r-base r-base-dev
# ---- RExpress
RUN mkdir /srv/RExpress
COPY . /srv/RExpress
WORKDIR /srv/RExpress
RUN npm install
WORKDIR /srv/RExpress/lib
CMD ["sh", "-c", "node ./api.js ${NB_WORKERS}"]
EXPOSE 80