I am trying to use Rstudio on a DigitalOcean server using a Rockudio docker . Since my experience with Linux servers is limited, this was a problem for me.
I can start Rstudio with:
docker run -dp 8787:8787 -v /root:/home/rstudio/ -e ROOT=TRUE rocker/hadleyverse
However, I would like to be able to disconnect the server and save it in a snapshot when I do not use it, but I do not need to reinstall the packages every time I do it.
Using the docker documentation on updating the image , I can create a container, install packages on this container and then commit the changes:
docker run -t -i rocker/hadleyverse /bin/bash install.r randomForest exit docker commit \<CONTAINER_ID> michael91/ms:v1
However, as soon as I make a fix, I will not be able to correctly launch the updated image. I am trying to run it as follows:
docker run -dp 8787:8787 -v /root:/home/rstudio/ -e ROOT=TRUE michael91/ms:v1
When I do this, the Rstudio server does not activate, as it happens when I launch the original rocker / hadleverse version. I tried committing with and without installing packages; In any case, this does not work. Obviously, I'm doing something wrong, but I'm not sure what. If anyone could offer me some guidance, I would really appreciate it.
Edit: Thanks a lot VonC; what did the trick.
source share