Deploying Shiny app with Docker and Shiny Server

35 views
Skip to first unread message

smit...@appstate.edu

unread,
Oct 6, 2017, 9:04:50 AM10/6/17
to Shiny - Web Framework for R
Hey everyone,

I am attempting to deploy a Shiny app on AWS (Ubuntu 16.04) with Docker and Shiny server.  So far I have a Dockerfile that looks like this:

FROM rocker/shiny:latest

#adds server.R, ui.R, and source files to project directory
ADD
. /srv/shiny-server/app_energy

#loads necessary packages
RUN sudo R
-e "install.packages(c('shiny', 'dplyr', 'plotly', 'magrittr', 'ggplot2', 'lubridate'...))"

EXPOSE
3838

CMD
["/usr/bin/shiny-server.sh"]


To start the app I run:


docker run --rm -p 3838:3838 energy

or:


docker run --rm -p 3838:3838 \ 
    -v /srv/shinyapps/:/srv/shiny-server/ \
    -v /srv/shinylog/:/var/log/shiny-server/ \
energy


The first gives me:


ERROR: An error has occurred. Check your logs or contact the app author for clarification.


While the second gives me a 'page not found error.'

Any thoughts or tips?  All help would be greatly appreciated.

Thank you,

Kiefer Smith

Reply all
Reply to author
Forward
0 new messages