0
我想安装一个RCurl到Docker容器,重新混合this Dockerfile,但失败。所以Docker:如何将RCurl安装到Docker容器?
如何将RCurl安装到Docker容器?
Dockerfile
$ cat Dockerfile FROM r-base RUN apt-get -y install r-base RUN pip install rpy2 RUN apt-get -y install libcurl4-openssl-dev #setup R configs RUN echo "r <- getOption('repos'); r['CRAN'] <- 'http://cran.us.r-project.org'; options(repos = r);" > ~/.Rprofile RUN Rscript -e "install.packages('yhatr')" RUN Rscript -e "install.packages('ggplot2')" RUN Rscript -e "install.packages('plyr')" RUN Rscript -e "install.packages('reshape2')" RUN Rscript -e "install.packages('forecast')" RUN Rscript -e "install.packages('stringr')" RUN Rscript -e "install.packages('lubridate')" RUN Rscript -e "install.packages('randomForest')" RUN Rscript -e "install.packages('rpart')" RUN Rscript -e "install.packages('e1071')" RUN Rscript -e "install.packages('kknn')" RUN Rscript -e "install.packages('RCurl')" RUN Rscript -e "install.packages('rjson')"
泊坞instalaltion失败
trying URL 'https://cran.rstudio.com/src/contrib/RCurl_1.95-4.8.tar.gz' Content type 'application/x-gzip' length 916934 bytes (895 KB) ================================================== downloaded 895 KB * installing *source* package ‘bitops’ ... ** package ‘bitops’ successfully unpacked and MD5 sums checked ** libs gcc -std=gnu99 -I/usr/share/R/include -DNDEBUG -fpic -g -O2 -fdebug-prefix-map=/build/r-base-3.3.2=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g -c bit-ops.c -o bit-ops.o gcc -std=gnu99 -I/usr/share/R/include -DNDEBUG -fpic -g -O2 -fdebug-prefix-map=/build/r-base-3.3.2=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g -c cksum.c -o cksum.o gcc -std=gnu99 -shared -L/usr/lib/R/lib -Wl,-z,relro -o bitops.so bit-ops.o cksum.o -L/usr/lib/R/lib -lR installing to /usr/local/lib/R/site-library/bitops/libs ** R ** preparing package for lazy loading ** help *** installing help indices ** building package indices ** testing if installed package can be loaded * DONE (bitops) * installing *source* package ‘RCurl’ ... ** package ‘RCurl’ successfully unpacked and MD5 sums checked checking for curl-config... no Cannot find curl-config ERROR: configuration failed for package ‘RCurl’ * removing ‘/usr/local/lib/R/site-library/RCurl’ The downloaded source packages are in ‘/tmp/RtmpJrfUvL/downloaded_packages’ Warning message: In install.packages("RCurl") : installation of package ‘RCurl’ had non-zero exit status ---> b8de6bc67379 Removing intermediate container e8c17d0306ef
你做错了。 _安装二进制packages_。看看我们的Rocker项目是做什么的。 –
@DirkEddelbuettel所以通过摇杆手册,我需要建立一个容器与这个Dockerfile [这里](https://github.com/rocker-org/hadleyverse/blob/master/Dockerfile)下hadleyverse是从'安装二进制文件'[这里](https://github.com/rocker-org/rocker/wiki)?不幸的是,hadleyverse wiki是空的 – hhh
SO,'Rocker'项目的(众多!!)Dockerfiles,它们创建了例如r-base容器。 _看看我们做什么,让你的生活更轻松。 –