Ready in 2 minutes

Install FlatRun

One command sets up everything on your server.

$ curl -fsSL https://raw.githubusercontent.com/flatrun/installer/main/scripts/install.sh | sudo bash
Docker, agent, UI, proxy, firewall
MIT Licensed
Ubuntu, Debian, CentOS
http://YOUR_SERVER_IP:8080/setup

Other Ways to Install

The script above is the fastest path. These options are for manual or custom setups.

Agent Binary

Install the agent manually on Linux or macOS.

Linux (amd64)
VERSION=$(curl -s https://api.github.com/repos/flatrun/agent/releases/latest | grep '"tag_name"' | cut -d'"' -f4 | tr -d 'v')
curl -LO https://github.com/flatrun/agent/releases/download/v$VERSION/flatrun-agent-$VERSION-linux-amd64.tar.gz
tar -xzf flatrun-agent-$VERSION-linux-amd64.tar.gz
sudo mv flatrun-agent /usr/local/bin/
macOS (arm64)
VERSION=$(curl -s https://api.github.com/repos/flatrun/agent/releases/latest | grep '"tag_name"' | cut -d'"' -f4 | tr -d 'v')
curl -LO https://github.com/flatrun/agent/releases/download/v$VERSION/flatrun-agent-$VERSION-darwin-arm64.tar.gz
tar -xzf flatrun-agent-$VERSION-darwin-arm64.tar.gz
sudo mv flatrun-agent /usr/local/bin/

Use linux-arm64 for ARM Linux or darwin-amd64 for Intel Macs.

Run as Service

Register the agent as a systemd service for automatic startup.

systemd
sudo tee /etc/systemd/system/flatrun-agent.service > /dev/null <<EOF
[Unit]
Description=FlatRun Deployment Agent
After=network.target docker.service
Requires=docker.service

[Service]
Type=simple
ExecStart=/usr/local/bin/flatrun-agent --config /etc/flatrun/config.yml
Restart=always
RestartSec=5

[Install]
WantedBy=multi-user.target
EOF

sudo mkdir -p /etc/flatrun
sudo systemctl daemon-reload
sudo systemctl enable --now flatrun-agent

UI Dashboard

The web dashboard for managing deployments through a browser.

Nginx Configuration
server {
    listen 80;
    server_name flatrun.example.com;
    root /var/www/flatrun-ui/dist;
    index index.html;

    location / {
        try_files $uri $uri/ /index.html;
    }

    location /api {
        proxy_pass http://localhost:8090;
        proxy_set_header Host $host;
        proxy_set_header X-Real-IP $remote_addr;
    }
}

Build from Source

Clone and build the agent or UI yourself.

Agent (Go)
git clone https://github.com/flatrun/agent.git
cd agent && go build -o flatrun-agent ./cmd/agent
./flatrun-agent --config config.yml
UI (Node.js)
git clone https://github.com/flatrun/ui.git
cd ui && npm install && npm run build
# Serve the dist/ folder with any web server

Requirements

  • Linux server (Ubuntu 20.04+, Debian 11+, or CentOS 8+)
  • 1 GB RAM minimum, 2 GB recommended
  • Docker (installed automatically by the script)
  • Root or sudo access

See the full installation guide for details on what the script does and manual alternatives.

Star us on GitHub