You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Prophet has rstan as a dependency which has been updated recently.
The last change of rstan introduce a new dependency to V8 package which needs some headers which are not available in Alpine linux (at least not that I know of).
Here's a tweak I use which is not a long term solution:
# Install all prophet dependencies but rstan
RUN installr -t "linux-headers gfortran g++" StanHeaders ggplot2 inline gridExtra loo pkgbuild BH dygraphs extraDistr grid methods rstantools scales stats tidyr xts
# Add system requirement for rstan (can't use installr when installing package from source, or with option dependencies != NA)
RUN apk add g++ linux-headers gfortran
# Install rstan and prophet
RUN Rscript -e 'install.packages("https://cran.r-project.org/src/contrib/Archive/rstan/rstan_2.19.3.tar.gz", type = "source")'
RUN Rscript -e 'install.packages("prophet", repos = "https://cloud.r-project.org/", dependencies = "Depends")'
You're right, libnode-dev contains v8.h and some other requirements.
I tried something like that:
FROM rhub/r-minimal
# V8 package requirements search for headers in v8 folder, not node
RUN apk add libnode-dev && ln -s /usr/include/node /usr/include/v8
RUN installr -t "linux-headers gfortran g++" prophet
Activity
gaborcsardi commentedon Jul 9, 2020
V8 is in
libnode-dev, but the R package does not find it automatically, unfortunately.Are you interested in making a PR to the README and example Dockerfile?
denrou commentedon Jul 9, 2020
You're right,
libnode-devcontainsv8.hand some other requirements.I tried something like that:
Unfortunately without much success
Yes I can make a PR to the README
gaborcsardi commentedon Jul 9, 2020
Yeah, look at the error message for
installr V8, it tells you how to set the location of V8, but we'll need to useinstall.packages()for this.Thanks much!
denrou commentedon Jul 9, 2020
I tried with a custom
install.packages(), but no luck, best I can do is:Resulting with
So I'm missing
lv8_libplatformbut I don't know where to find itgaborcsardi commentedon Oct 24, 2020
I merged this manually because I could not push to the PR. Thanks!