rocker-org / rocker-versioned

Run current & prior versions of R using docker
https://hub.docker.com/r/rocker/r-ver
GNU General Public License v2.0
297 stars 169 forks source link

curl command not found in container #157

Closed nickforr closed 5 years ago

nickforr commented 5 years ago

I'm using bash in the rocker/verse container (having run docker exec -ti <container-id> bash) and trying to download something using curl but I'm seeing bash: curl: command not found

I know I can install this with apt-get etc but I'm wondering why it's not available given that the dockerfiles themselves use curl commands?

Thanks

eddelbuettel commented 5 years ago

There are many commands available for Linux, and we cannot ship all of them. On the margin each of these requests is "useful" and "has a point" -- but we need to draw a line somewhere.

Maybe you can "fix" your download problem using the curl package from R?

In short, I understand your issue but still think we may want to refrain from installing. But it is not clear cut as the curl (command-line) package is indeed small-ish - 400kb on my Ubuntu 19.04 desktop.

nickforr commented 5 years ago

Thanks, I can work around this ok. I think it’s just I haven’t fully understood the relationship between commands in the Dockerfile (where curl is used) and what’s then available in the container when it’s running.

(Happy for you to close this and thanks for all your efforts with rocker, it’s very useful).

eddelbuettel commented 5 years ago

Can you link to the Dockerfile in question? If and when a command is used, it should indeed be in the container (e.g. install.r). Could you by chance be confusing different Dockerfiles and containers?

nickforr commented 5 years ago

It's in the r-ver dockerfile; line 72 looks to install curl and line 75 looks to use it: https://github.com/rocker-org/rocker-versioned/blob/master/r-ver/Dockerfile

eddelbuettel commented 5 years ago

Indeed. But listed under BUILDDEPS so maybe a temporary use.

nickforr commented 5 years ago

Ah, I missed line 126: apt-get remove --purge -y $BUILDDEPS Thanks.