Comments (13)
Hi, I have the same Problem with it saying Not Found for the markdown part/window.
Opening a markdown project with http://localhost:3838/sample-apps/rmd/index.Rmd works. How do I fix the Not Found part?
Thanks
Using shiny-verse
from shiny.
First, did you look at the details in README.md for the shiny Rocker container. It has quite some hints.
Second, the ability to not run the rmd/
appears to be due to it expecting index.html
but there is not. Use this path: http://localhost:3838/sample-apps/rmd/index.Rmd and you will see the demo.
Similarly, one could probably fix the index.html to point to rmd/index.Rmd ...
Third, maybe you want shiny-verse so that you don't have to install all those packages by hand.
from shiny.
If it is shiny-server the apps below /srv/shiny-server
should be running because the shiny server daemon is running. You should not have to also invoke it as app via rmarkdown::run()
.
Also, just as a style, I would have written
RUN install.r rstan shiny rmarkdown shinydashboard shinyWidget # add other ones here
as we have install.r
for this, and it know about the repo to source from.
from shiny.
If it is shiny-server the apps below
/srv/shiny-server
should be running because the shiny server daemon is running. You should not have to also invoke it as app viarmarkdown::run()
.Also, just as a style, I would have written
RUN install.r rstan shiny rmarkdown shinydashboard shinyWidget # add other ones here
as we have
install.r
for this, and it know about the repo to source from.
Thanks. When I use "CMD ["/usr/bin/shiny-server.sh"]", although I get the Shiny working, the sample app for rmarkdown doesn't render. When I open the chrome debugger, it shows "http://localhost:3838/sample-apps/rmd/ 404 (Not Found)". I have installed "rmarkdown".
from shiny.
@flololan Here's how you could test this. Make an app in there to see what version of rmarkdown is being run. The app folder naem could be called rmarkdown. Then put the following simple ui and server scripts in there to build a shiny app (we know this renders) to determine what version of rmarkdown you have:
The ui.R script
fluidPage(
hr(),
fluidRow(column(3, verbatimTextOutput("value")))
)
The server.r script
function(input, output) {
output$value <- renderPrint({ utils::packageVersion('rmarkdown') })
}
Then build and rerun http://localhost:3838/rmarkdown/ in the browser. It should take you to the screen and display the version of rmarkdown you have. If it is 1.18 that's the culprit.
If you install rmarkdown from github in your Dockerfile you'd get a newer version without this bug and all is well.
from shiny.
Very strange that you would get different behavior from building locally; hub is building automatically from the same Dockerfile.
I see some 404's on the example shiny file both way though, but not sure where to start debugging that one. Maybe @wch has better insight here.
from shiny.
It's possible that you are running into rstudio/shiny#2385.
We have a fix that was merged into the v1.3.2-patch branch: rstudio/shiny#2386
We also submitted a new version, 1.3.2, to CRAN, and hopefully it will be accepted soon.
from shiny.
Thanks for your investigation!
Yes, rstudio/shiny#2385 looks like the same issue:
$ docker container run --rm -it rocker/shiny-verse //usr/local/bin/Rscript -e 'library(shiny); sessionInfo()' | grep shiny
[1] shiny_1.3.1
$ docker container run --rm -it my/peppa //usr/local/bin/Rscript -e 'library(shiny); sessionInfo()' | grep shiny
[1] shiny_1.2.0
I'll periodically check https://cran.r-project.org/package=shiny and https://hub.docker.com/r/rocker/shiny-verse/builds to see if the issue is gone.
from shiny.
Very strange that you would get different behavior from building locally; hub is building automatically from the same Dockerfile.
Here is version of 'rocker/shiny-verse:latest' on my machine:
$ docker image history rocker/shiny-verse:latest
IMAGE CREATED CREATED BY SIZE COMMENT
0052bf0992e2 39 hours ago /bin/sh -c apt-get update -qq && apt-get -y … 451MB
<missing> 41 hours ago /bin/sh -c #(nop) CMD ["/usr/bin/shiny-serv… 0B
<missing> 41 hours ago /bin/sh -c #(nop) COPY file:5a292866d694cfb8… 397B
<missing> 41 hours ago /bin/sh -c #(nop) EXPOSE 3838 0B
<missing> 41 hours ago /bin/sh -c wget --no-verbose https://downloa… 494MB
<missing> 42 hours ago /bin/sh -c apt-get update && apt-get install… 313MB
<missing> 2 days ago /bin/sh -c #(nop) CMD ["R"] 0B
<missing> 2 days ago /bin/sh -c apt-get update && apt-get insta… 505MB
<missing> 2 days ago /bin/sh -c #(nop) ENV R_VERSION=3.5.3 LC_AL… 0B
<missing> 2 days ago /bin/sh -c #(nop) ARG BUILD_DATE 0B
<missing> 2 days ago /bin/sh -c #(nop) ARG R_VERSION 0B
<missing> 2 days ago /bin/sh -c #(nop) LABEL org.label-schema.li… 0B
<missing> 3 weeks ago /bin/sh -c #(nop) CMD ["bash"] 0B
<missing> 3 weeks ago /bin/sh -c #(nop) ADD file:843b8a2a9df1a0730… 101MB
and my build:
$ docker image history my/peppa:latest
IMAGE CREATED CREATED BY SIZE COMMENT
29b53cd5a15d 18 hours ago /bin/sh -c #(nop) EXPOSE 80 0B
c91228826358 18 hours ago /bin/sh -c #(nop) VOLUME [/var/log/shiny-se… 0B
93f2857a086c 18 hours ago /bin/sh -c #(nop) VOLUME [/var/lib/shiny-se… 0B
9d96ef866b22 18 hours ago /bin/sh -c #(nop) COPY dir:0f7dcb89f712c8059… 3.05MB
b3129dbb166f 18 hours ago /bin/sh -c #(nop) COPY file:c11f72f43a4fc04d… 338B
1216f39e73f6 18 hours ago /bin/sh -c #(nop) COPY file:2f2309baddd5d793… 569B
25d5a87c4b7a 18 hours ago /bin/sh -c apt-get update -qq && RUNTIMEDE… 242MB
15eb12c26e61 3 weeks ago /bin/sh -c #(nop) CMD ["/usr/bin/shiny-serv… 0B
<missing> 3 weeks ago /bin/sh -c #(nop) COPY file:5a292866d694cfb8… 397B
<missing> 3 weeks ago /bin/sh -c #(nop) EXPOSE 3838 0B
<missing> 3 weeks ago /bin/sh -c wget --no-verbose https://downloa… 494MB
<missing> 3 weeks ago /bin/sh -c apt-get update && apt-get install… 313MB
<missing> 3 weeks ago /bin/sh -c #(nop) CMD ["R"] 0B
<missing> 3 weeks ago /bin/sh -c apt-get update && apt-get insta… 505MB
<missing> 3 weeks ago /bin/sh -c #(nop) ENV R_VERSION=3.5.3 LC_AL… 0B
<missing> 3 weeks ago /bin/sh -c #(nop) ARG BUILD_DATE 0B
<missing> 3 weeks ago /bin/sh -c #(nop) ARG R_VERSION 0B
<missing> 3 weeks ago /bin/sh -c #(nop) LABEL org.label-schema.li… 0B
<missing> 3 weeks ago /bin/sh -c #(nop) CMD ["bash"] 0B
<missing> 3 weeks ago /bin/sh -c #(nop) ADD file:843b8a2a9df1a0730… 101MB
I didn't install biocLite.R
and added some shiny apps on the top, but the main difference is dates of the layers. So, I think some layers were taken from the cache.
from shiny.
@vvolodko good call, hub did have caching enabled. I've unchecked that now so the nightly builds should pick up the new packages, including hopefully the 1.3.2 version when it hits the CRAN mirrors.
from shiny.
I have a similar issue. When I go to the url "localhost:3838/my_app" it shows me "not found". The following is my dockerfile. Any ideas? Thanks
# get shiny serves plus tidyverse packages image
FROM rocker/shiny-verse:latest
# system libraries of general use
RUN apt-get update && apt-get install -y \
sudo \
pandoc \
pandoc-citeproc \
libcurl4-gnutls-dev \
libcairo2-dev \
libxt-dev \
libssl-dev \
libssh2-1-dev \
nmap \
vim
# install R packages required
# (change it dependeing on the packages you need)
RUN R -e "dotR <- file.path(Sys.getenv('HOME'), '.R'); if (!file.exists(dotR)) {dir.create(dotR)}; M <- file.path(dotR, 'Makevars'); if (!file.exists(M)) file.create(M);cat('\nCXX14FLAGS=-O3 -march=native -mtune=native -fPIC', 'CXX14=g++', file = M, sep = '\n', append = TRUE)"
RUN R -e "install.packages('rstan', repos='http://cran.rstudio.com/')"
RUN R -e "install.packages('shiny', repos='http://cran.rstudio.com/')"
RUN R -e "install.packages('rmarkdown', repos='http://cran.rstudio.com/')"
RUN R -e "install.packages('shinydashboard', repos='http://cran.rstudio.com/')"
RUN R -e "install.packages('shinyWidgets', repos='http://cran.rstudio.com/')"
RUN R -e "install.packages('shinycssloaders', repos='http://cran.rstudio.com/')"
RUN R -e "install.packages('magrittr', repos='http://cran.rstudio.com/')"
RUN R -e "install.packages('glue', repos='http://cran.rstudio.com/')"
RUN R -e "install.packages('DT', repos='http://cran.rstudio.com/')"
RUN R -e "install.packages('plotly', repos='http://cran.rstudio.com/')"
RUN R -e "install.packages('flexdashboard', repos='http://cran.rstudio.com/')"
RUN R -e "install.packages('Rcpp', repos='http://cran.rstudio.com/')"
RUN R -e "install.packages('chron', repos='http://cran.rstudio.com/')"
RUN R -e "install.packages('zoo', repos='http://cran.rstudio.com/')"
RUN R -e "install.packages('lubridate', repos='http://cran.rstudio.com/')"
RUN R -e "install.packages('strucchange', repos='http://cran.rstudio.com/')"
RUN R -e "install.packages('tsoutliers', repos='http://cran.rstudio.com/')"
RUN R -e "install.packages('anomalize', repos='http://cran.rstudio.com/')"
RUN R -e "install.packages('changepoint', repos='http://cran.rstudio.com/')"
RUN R -e "install.packages('data.table', repos='http://cran.rstudio.com/')"
RUN R -e "install.packages('tsoutliers', repos='http://cran.rstudio.com/')"
RUN R -e "install.packages('quantreg', repos='http://cran.rstudio.com/')"
RUN R -e "install.packages('future', repos='http://cran.rstudio.com/')"
RUN R -e "install.packages('furrr', repos='http://cran.rstudio.com/')"
RUN R -e "install.packages('purrr', repos='http://cran.rstudio.com/')"
RUN R -e "install.packages('prophet', repos='http://cran.rstudio.com/')"
RUN R -e "install.packages('futile.logger', repos='http://cran.rstudio.com/')"
RUN R -e "install.packages('here', repos='http://cran.rstudio.com/')"
# copy the app to the image - to change
COPY my_app /srv/shiny-server/my_app
COPY Dockerfile /srv/shiny-server/
# select port
EXPOSE 3838
# allow permission
RUN sudo chown -R shiny:shiny /srv/shiny-server
# run app
# CMD ["/usr/bin/shiny-server.sh"]
CMD ["R", "-e rmarkdown::run('/srv/shiny-server/my_app/my_app.Rmd',shiny_args=list(host='0.0.0.0',port=3838))"]
from shiny.
@eddelbuettel Is this possibly because the rmarkdown package being used is v. 1.18 and is related to this: rstudio/rmarkdown#1731 and this rstudio/rmarkdown#1714?
from shiny.
I do not know those two issues, sorry. I am also unaware of any systemic issues with rmarkdown.
from shiny.
Related Issues (20)
- /usr/bin/shiny-server.sh: no such file or directory error HOT 2
- Shiny version HOT 2
- Remove /tmp/downloaded_packages HOT 4
- no xtail in Shiny:Devel HOT 1
- New Version of Shiny Server HOT 5
- Update shiny-verse to later R-ver HOT 3
- nginx reverse proxy - shiny server issue HOT 1
- request for merge of shiny-verse and verse (i.e. Tidyverse, LaTeX, and Shiny all together) HOT 2
- Can't read environment variable set in docker-compose HOT 5
- Permission denied when running rocker/shiny-verse and rocker/shiny images HOT 4
- Regression for running as non-root user? HOT 6
- [Resolved] Where is application output? print, logging, etc. HOT 2
- Security Vulnerabilities HOT 3
- rocker/shiny-verse latest vs 3.6.3 HOT 4
- rocker/shiny-verse latest vs 3.6.3 HOT 1
- Provide a bootstrap endpoint HOT 1
- doesn't work on ARM architecture HOT 3
- Basic setup for 3.6.3 does not work for 4.0.3? HOT 1
- Missing git tags HOT 1
- Unable to save to mounted volume HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from shiny.