Runway
Runway is built and operated in the EU!

Multi-process

A Procfile is used to orchestrate your application, especially if you have multiple components that make up your application and work in tandem. The file is structured in the following format:

<process type>: <command>

(The brackets are not included.)

Process types

The available process types are:

Specify command-line arguments

If your app needs command-line arguments to start, you can put those into the Procfile:

Procfile
web: your-app-on-runway server --some-argument=123

Environment

All of the processes share the same image (that is build by Runway’s builder) and configuration supplied via runway app config set, but they run in independent environments and cannot share local memory.

The process type worker can access the web process via HTTP on the loopback interface and the port on which the web process listens. So for example, your Golang application without a custom port can be reached via this from the worker process:

curl http://localhost:5000

Usage

Build your application either by utilizing a CLI library (as outlined in the guide to faster builds) or following the cmd pattern (outlined in the monorepo guide).

Add a Procfile to your application and configure the process types appropriately:

Procfile
web: your-app-on-runway -daemon
worker: your-app-on-runway -worker

Individual binaries (cmd/server, cmd/worker) work like this:

Procfile
web: server
worker: worker
Runway CLI
runway app config set BP_GO_TARGETS=./cmd/server:./cmd/worker
project.toml
[build]
  [[build.env]]
    name = "BP_GO_TARGETS"
    value = "./cmd/server:./cmd/worker"