Skip to content

Instantly share code, notes, and snippets.

@Inkimar
Created March 6, 2022 10:35
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save Inkimar/2c25f3543428f69c12d8db348d606501 to your computer and use it in GitHub Desktop.
Save Inkimar/2c25f3543428f69c12d8db348d606501 to your computer and use it in GitHub Desktop.
Dockerfile, ukraina
FROM rocker/r-ubuntu:20.04
LABEL maintainer="inkimar <inkimar>"
RUN apt-get update && apt-get install -y --no-install-recommends \
sudo \
libcurl4-gnutls-dev \
libcairo2-dev \
libxt-dev \
libssl-dev \
libssh2-1-dev \
&& rm -rf /var/lib/apt/lists/*
# custom packages, my addition
RUN sudo su - -c "R -e \"install.packages(c('DT','devtools','remotes','dplyr','dbplyr','shinyjs','sf','leaflet','leafpop','mapview'), repos='http://cran.rstudio.com/')\""
RUN echo "local(options(shiny.port = 3838, shiny.host = '0.0.0.0'))" > /usr/lib/R/etc/Rprofile.site
RUN addgroup --system app \
&& adduser --system --ingroup app app
WORKDIR /home/app
COPY app .
RUN chown app:app -R /home/app
USER app
EXPOSE 3838
CMD ["R", "-e", "shiny::runApp('/home/app')"]
@Inkimar
Copy link
Author

Inkimar commented Mar 6, 2022

https://github.com/obrl-soil/h3jsr

#RUN sudo su - -c "R -e "install.packages(c('h3jsr'), repos='https://cran.r-project.org)\""
#RUN sudo su - -c "R -e "remotes::install_github("obrl-soil/h3jsr")""

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment