Producing and Reproducing Results

A system for embedded scientific computing and reproducible research with R. The OpenCPU server exposes a simple but powerful HTTP api for RPC and data interchange with R. This provides a reliable and scalable foundation for statistical services or building R web applications. The OpenCPU server runs either as a single-user development server within the interactive R session, or as a multi-user Linux stack based on Apache2. The entire system is fully open source and permissively licensed. The OpenCPU website has detailed documentation and example apps.



  • Fix parsing for length 1 matrix objects parameters
  • Version bump for R 3.6.0


  • Replace sys::eval_safe() with unix::eval_safe()


  • Replace devtools dependency with remotes
  • Cloud server: always keep ocpu system lib on the path


  • Webhook now uses temporary folder inside destination folder #316


  • Increase default key length to 13 to prevent hash collisions
  • Docker: start cron daemon by default
  • Cloud server: remove dependency on libcurl3 for Ubuntu Bionic
  • Cloud server: update package library
  • Docker / Launchpad: update rstudio-server
  • Docker: workaround bug in rstudio (explicitly disable apparmor)
  • rapache handler now properly closes sink() even in case of system errors
  • fix regression from security patch: catch timeout errors


  • Internally switch to condition system to raise ocpu-success
  • Move all reading of files inside the forked process
  • Check for path traversal for GET requests. Note that you should really enable AppArmor in production.
  • Faster serialization in sys::eval_save() in sys 1.6


  • Support auth_token in webhook (either set /etc/opencpu/secret.conf or GITHUB_PAT in /etc/opencpu/Renviron)
  • Pass down 'rapache' option to webhook installer process to load proper config files


  • Fix bug where only the first package would actually get preloaded
  • The /ocpu/info API shows some additional config/system info


  • Single user server: flush.console() after printing logs to the console
  • Single user server: kill child process if a worker hits timeout
  • Support JSON null values for rlimits in config
  • Add URL parameter 'mail_owner' to webhook url (default is TRUE)
  • Cloud server: automatically add libjvm path to ldpaths (internal)

  • Removed the manual call to gc() at the end of each request because it is very slow


  • Much improved support for UTF-8 (requires updated 'webutils' and 'evaluate')
  • Multipart requests now support binary form-data fields in 'appplication/rds', 'application/rprotobuf', or 'application/json' types. This makes it easier to push objects from client-server or server-server.
  • RApache: use webutils instead of apreq to parse request body.
  • Single user server: fix for empty POST requests with no 'Content-Length' header
  • Ignore double slashes in URL
  • Support pkg::object and session::object alias for ./R/object
  • Added a 'strings' data object for testing character encodings
  • Add support for 'haven' output types


  • Hotfix release for performance regression in cloud server (#239)


  • ocpu_start_app() now automatically checks for app updates if online
  • Fix for posting scripts (empty args)
  • Support figures with error messages (for invalid graphic parameters)
  • linux: show informative error message when tmp dir cannot be created
  • opencpu-cache: require at least version 1.12 of nginx (fixes HTTP/2 bug)
  • fix year of paper in citation file
  • fix link to pdf manual in test page
  • Add parameter 'no_cache' to single user server for development
  • HTTP OPTIONS now returns 'Access-Control-Allow-Methods' header for CORS preflight
  • Better email notification: to=pusher, cc=owner, bcc=archive
  • Webhook: use sys pkg instead of system2 for running rscript
  • Webhook: make email sending more robust
  • Internal function trigger_webhook() to test webhook (should move to client pkg)
  • Remove 'public.url' from server.conf
  • Add 'update_apps()' function for convenience


  • Major rewrite :)


  • Fix for /man/html (use tools::Rd2HTML)


  • Fix bug to support non interactive: Rscript -e 'opencpu::opencpu$debug(4000)'
  • Suggest: feather


  • Workaround for unloadNamespace bug in R 3.3.0


  • Lazy load import packages using pkg::name instead of importFrom()


  • Replace 'RProtoBuf' dependency with 'protolite'


  • Bump version to sync with cloud server
  • Workaround in eval_fork for mccollect race condition bug


  • Fix for case sensitive Github usernames


  • Support Auth over CORS


  • Add a CITATION file
  • Fix for new rhttpd system in R 3.2.0


  • Add support for "Accept" request header
  • Update /man/html stylesheet
  • Add back support for URL parameters
  • Only use AppArmor if available
  • Add default robots.txt and favicon to cloud server
  • Cloud server now sets HOME envvar to tempdir()
  • Add support for x12345::foo arguments
  • Remove ocpu_tmp_ prefix for session directories in tmp_library
  • Bunch of internal changes to support Fedora/Redhat RPM packages


  • Add support for application/json payloads for Github webhooks
  • Disable forks in OSX (again) due to issues with rJava
  • Disable unloading of packages in eval_current due to issues with rJavas
  • Fix for eol in csv/tab output on Windows
  • Fix for hash collisions with large amounts of sessions
  • Add whitepaper vignette and url to package


  • Bug fix for JSON input data
  • Bump jsonlite depends to 0.9.8


  • Make session-key lenght configurable, default to 9.


  • HTTP 201 301 302 now uses absolute URL in Location header
  • Don't print call for internal stop() errors
  • Change vignette builder to knitr
  • Update devtools and httr dependencies
  • Replace CR+LF by LF before parsing code snippets
  • Add support for index.html in package root dir
  • Disable compression in storring sessions to gain speed
  • Clean up parsing code


  • Add support for private github repositories using access token authentication.
  • Use ~/.opencpu.conf as primary config file for single user server.
  • Disable hyperlinks in HTML man pages.
  • Bug fix for rscripts on the cloud server.
  • Experimental support for dot-dot-dot arguments.


  • Don't send attachement header for SVG anymore.
  • Upgrade rApache to 1.2.5: avoid receiveBin() when apreq alread parsed
  • Start using HTTP 405 instead of 400 for invalid methods


  • Use latest version of jsonlite
  • Better support for lazy load data API
  • Moved CRON scripts to update cran, bioc, github libraries inside the package
  • Use rstudio proxy when single-user server is loaded in rstudio-server.


  • Replaced dependency RJSONIO with jsonlite for all toJSON/fromJSON
  • Add support for pkg/data API
  • Improve CI email notifications
  • add /console shortcut
  • correct MIME headers for fonts


  • Adding Github CI stuff
  • New config parameters: "public.url" and "smtp.server", "timelimit.webhook"


  • Version bump for CRAN release.
  • Detect /ocpu/user libraries from /etc/passwd.


  • Don't fork on MAC for "safe" requests (to reduce risk of fork issues)
  • Temporary change fork method to psock method on OSX because of problems in Mavericks.
  • Adding opencpu$view() to take advantage of Rstudio viewing panel if available
  • Set quick=true for install_github
  • Use bitmapType="cairo" if available
  • Temporary implementation of HTTP OPTIONS for CORS in chrome.
  • Adding Access-Control-Allow-Headers and Access-Control-Expose-Headers to support CORS preflighting.


  • Fixed bug when timeout > 60s (reported by Jordy Coolen)
  • Fixed nginx warning in the cloud server
  • Upgrade evaluate to 0.5.1
  • Add support for Apache 2.4 / Ubuntu Saucy in cloud server with mpm_prefork


  • Invisible return values are now stored but not printed
  • Dependency update to evaluate 0.4.10


  • Capture output for install.packages, install_github and biocInstaller
  • Remove rapache library change in onAttach


  • Fix bugs for uploading files
  • Fix bugs for storing files from a session
  • Set default bitmap type to Cairo (to prevent problems with forks on MAC)

Reference manual

It appears you don't have a PDF plugin for this browser. You can click here to download the reference manual.


2.2.6 by Jeroen Ooms, 2 months ago (website) (devel)

Report a bug at

Browse source code at

Authors: Jeroen Ooms [aut, cre]

Documentation:   PDF Manual  

Task views: Web Technologies and Services, Model Deployment with R

Apache License 2.0 license

Imports evaluate, httpuv, knitr, jsonlite, remotes, sys, webutils, curl, rappdirs, zip, mime, protolite, brew, openssl

Suggests unix, haven, feather, pander, R.rsp, svglite

System requirements: pandoc, apparmor (optional)

Imported by LeArEst.

Suggested by OmicNavigator, distcomp.

See at CRAN