- 
                Notifications
    
You must be signed in to change notification settings  - Fork 29
 
Open
Description
Hello :)
I was trying to replicate the exact Dockerfile from a folder, but had to override the COPY line as there was no option to add a custom one like Cmd() - I had to use the below:
 docker <- suppressWarnings(dockerfile(deploy_folder,
     image = "trestletech/plumber",
     offline = FALSE,
     cmd = Cmd("api.R"),
     maintainer = NULL,
     container_workdir = NULL,
     entrypoint = Entrypoint("R",
                   params = list("-e",
                                 "pr <- plumber::plumb(commandArgs()[4]); pr$run(host='0.0.0.0', port=as.numeric(Sys.getenv('PORT')))")),
     filter_baseimage_pkgs = TRUE,
     ...))
  addInstruction(docker) <-containerit:::Copy(".","./")
print(docker)
#FROM trestletech/plumber
#COPY ["./", "./"]
#ENTRYPOINT ["R", "-e", "pr <- plumber::plumb(commandArgs()[4]); pr$run(host='0.0.0.0', port=as.numeric(Sys.getenv('PORT')))"]
#CMD ["api.R"]Could there be a Copy() function exported to achieve similar to above?
muschellij2
Metadata
Metadata
Assignees
Labels
No labels