Cloud Server: Ubuntu 16.04 (recommended)

# Requires Ubuntu 16.04 (Xenial)
sudo add-apt-repository -y ppa:opencpu/opencpu-2.0
sudo apt-get update 
sudo apt-get upgrade

# Installs OpenCPU server
sudo apt-get install -y opencpu-server
# Done! Open http://yourhost/ocpu in your browser

# Optional: installs rstudio in http://yourhost/rstudio
sudo apt-get install -y rstudio-server 

Fedora 24 / 25

Go here to add the opencpu repository. Also have look at the readme for rpm packages.

# Need to add repo first! (See link above)
sudo yum install opencpu-server

Debian / CentOS / Suse etc

See the readme for building deb or rpm packages from source for your platform in a few easy steps.

Server Manual PDF

The OpenCPU server manual PDF is the primary reference for installing and managing OpenCPU servers.

Local Single-User Server

# Install OpenCPU

# Run Apps directly from Github

# Install / remove apps

Docker (new!)

Images based on various platforms are published on dockerhub. The opencpu/rstudio is great for development: it runs both opencpu-server and rstudio-server:

# Run server as executable
docker run --name mybox -t -p 80:80 opencpu/rstudio

# OR: if port 80 is taken use port 8004
docker run --name mybox -t -p 8004:8004 opencpu/rstudio

Now simply open http://localhost/ocpu/ and http://localhost/rstudio/ in your browser! Login via rstudio with user: opencpu (passwd: opencpu) to build or install apps.

To connect to a running container (e.g. for installing system libraries) get a root shell:

# Replace 'mybox' with the container name or id
docker exec -i -t mybox /bin/bash

Use the opencpu/base image for deployments. Also see the docker readme.