powered by
Uploads a folder with a Dockerfile and supporting files to an instance and builds it
Dockerfile
docker_build(host = localhost, dockerfolder, new_image, folder = "buildimage", wait = FALSE, ...)
A host object.
Local location of build directory including valid Dockerfile
Name of the new image
Where on host to build dockerfile
Whether to block R console until finished build
Other arguments passed to the SSH command for the host
A table of active images on the instance
Dockerfiles are best practice when creating your own docker images, rather than logging into a Docker container, making changes and committing.
Best practices for writing Dockerfiles
An example Dockerfile for rOpensci
General R Docker images found at rocker-org
# NOT RUN { docker_build(localhost, "/home/stuff/dockerfolder" ,"new_image", wait = TRUE) docker_run(localhost, "new_image") # }
Run the code above in your browser using DataLab