R shiny IP and Port configuration

Thank you for nice product ShinyProxy.

I have a problem when I use ShinyProxy with my custom web app.

I made Dockerfile with your nice shinyproxy-template. But when I run my docker image built with Dockerfile my shiny app do not use but use default config.

With your nice tutorial, I have no problem. But my custom app doesn’t work…

This is my Dockerfile code. I use r-ver image to control my R version.

FROM rocker/r-ver:3.6.0


RUN apt-get update -qq && apt-get -y --no-install-recommends install \
  libxml2-dev \
  libcairo2-dev \
  libsqlite-dev \
  libpq-dev \
  libicu-dev \
  libbz2-dev \
  liblzma-dev \
  default-jdk \
  libssl-dev \
  libcurl4-openssl-dev \
  vim \
  unixodbc \
  unixodbc-dev \
  odbc-postgresql \
  && R CMD javareconf \
  && . /etc/environment

RUN Rscript -e "install.packages(c('Rmpfr', 'devtools', 'shiny', 'shinydashboard', 'shinyWidgets', 'ggthemes', 'highcharter','plotly', 'treemap', 'tidyverse', 'dplyr', 'plyr', 'data.table', 'sqldf','tibble', 'DT', 'formattable', 'extrafont', 'lubridate', 'RColorBrewer', 'reticulate'))"

RUN mkdir /root/MKT

COPY Rprofile.site /usr/lib/R/etc/


CMD ["R", "-e", "shiny::runApp('/root/MKT')"]

And other files like Rprofile.site is same.

Thank you for helping me.

I solved this problem myself :slight_smile:

I will share my problem.

The problem was R_HOME path. Shinyproxy_template inherits openanalytics/r-base images, but my Dockerfile is set to inherit rocker/r-ver:3.6.0. Because rocker’s R_Home path is /usr/local/lib/R, I have to change my code
COPY Rprofile.site /usr/lib/R/etc/
COPY Rprofile.site /usr/local/lib/R/etc/

This can be helpful to those who use rocker/r-ver image.
If you use other images, please check R path usinng Sys.getenv() function in containers.