Tools to Work with the 'Splash' JavaScript Rendering Service in R
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

38 lines
1.2KB

  1. % Generated by roxygen2: do not edit by hand
  2. % Please edit documentation in R/docker-splash.r
  3. \name{start_splash}
  4. \alias{start_splash}
  5. \title{Start a Splash server Docker container}
  6. \usage{
  7. start_splash(host = harbor::localhost, add_tempdir = FALSE)
  8. }
  9. \arguments{
  10. \item{host}{Docker host; defaults to `localhost`}
  11. \item{add_tempdir}{This is `FALSE` initially since you could try to run
  12. the splash image on a remote system. It has to be a local one for this to work.
  13. If `TRUE` then a local temporary directory (made with [tempdir()])
  14. will be added to the mount configuration for use with [render_file()]. You will need to
  15. ensure the necessary system temp dirs are accessible as a mounts. For
  16. macOS this means adding `/private` to said Docker config.}
  17. }
  18. \value{
  19. `harbor` `container` object
  20. }
  21. \description{
  22. If using this in an automation context, you should consider adding a
  23. `Sys.sleep(3)` (or higher) after starting the docker container.
  24. }
  25. \note{
  26. you need Docker running on your system and have pulled the container with
  27. [install_splash] for this to work. You should save the resultant `host`
  28. object for use in [stop_splash].
  29. }
  30. \examples{
  31. \dontrun{
  32. install_splash()
  33. splash_container <- start_splash()
  34. stop_splash(splash_container)
  35. }
  36. }