-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
37 lines (30 loc) · 812 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
#FROM rocker/r-ver:3.6.0
FROM rocker/r-apt:bionic
# install linux libs & binary R packages where possible
RUN apt-get update -qq && apt-get install -y \
libssl-dev \
libcurl4-gnutls-dev \
libsodium-dev \
libxml2-dev \
libz-dev \
r-cran-remotes \
r-cran-tidyverse \
r-cran-ggplot2 \
r-cran-plotly \
r-cran-janitor \
r-cran-scales \
r-cran-lubridate \
r-cran-paws \
r-cran-jsonlite
# Install packages from source
RUN R -e "remotes::install_github('rstudio/plumber')"
RUN R -e "remotes::install_github('Chicago/RSocrata')"
# Copy all, use .dockerignore in root to exclude
COPY . /
# Make start.sh an executable
RUN chmod +x start.sh
# Expose port, will not be respected by Heroku
EXPOSE 8080
# run root plumber.R on container startup
ENTRYPOINT ["./start.sh"]
CMD ["plumber.R"]