← Back to Docs

CLI Stack guide

CLI Stack mode generates a custom, minimal server setup managed entirely from the command line: no control panel, no bloat. You get Nginx as the reverse proxy, Systemd services for your app, and optionally a database and SSL certificate.

Stack types

Native Stack

Nginx as reverse proxy + Systemd service units for your backend and frontend. Designed for compiled binaries (Go, Rust) or Node.js apps running as persistent processes.

Use this for: Go APIs, Node/Bun servers, Astro SSR, and any app that runs as a standalone process.

Docker Stack

Installs Docker and Docker Compose. Nginx acts as the reverse proxy in front of your containers. Setup script handles Docker installation and basic hardening.

Use this for: containerized apps, multi-service setups using docker-compose.yml.

PHP Stack

Nginx + PHP 8.3 + PHP-FPM. Ready for PHP applications. Setup script installs and configures the full PHP environment.

Use this for: Laravel, WordPress, or any PHP application.

Configuration options

Field Description
Project Name Used as the service name in Systemd and Nginx. Letters, numbers, hyphens, underscores only.
Domain Your site's domain (e.g. myapp.com). Used in the Nginx vhost and SSL certificate.
Timezone IANA timezone name (e.g. Asia/Jakarta, UTC). Sets the VPS system timezone.
Backend Port The local port your backend app listens on (e.g. 8080). Nginx proxies to this port internally.
Frontend Port The local port your frontend app listens on (e.g. 4321). Must differ from the backend port.
Server User The Linux user that will own and run your services. Created automatically by the setup script. Default: deploy.
Database PostgreSQL, MySQL, or MariaDB will be installed and configured. Choose None if you're using a managed DB or SQLite.
Enable SSL Installs Certbot and issues a Let's Encrypt certificate for your domain. Requires DNS to point to the VPS before running.
Enable Firewall Configures UFW to allow only SSH (22), HTTP (80), and HTTPS (443). All other ports are blocked.
Disable Root Login Disables direct SSH login for the root user. Make sure you have another SSH key-based user before enabling this.

What's in the generated package

After downloading, the zip contains:

your-project-deploy.zip
├── README.md               ← Read this first
├── setup.sh                ← Main setup script (run this)
├── nginx/
│   └── nginx.conf          ← Nginx vhost configuration
└── services/
    ├── backend.service     ← Systemd unit for your backend
    └── frontend.service    ← Systemd unit for your frontend

Running the package

  1. 1

    Upload to your VPS

    scp your-project-deploy.zip user@your-server-ip:~/
    ssh user@your-server-ip
    unzip your-project-deploy.zip
  2. 2

    Review the files

    cat README.md
    cat setup.sh
    cat nginx/nginx.conf
  3. 3

    Run the setup script

    chmod +x setup.sh
    sudo ./setup.sh

    The script installs packages, creates the server user, configures Nginx, and optionally sets up the firewall and SSL.

  4. 4

    Deploy your application

    Copy your compiled binary or app files to the server, then install the Systemd service files and start them:

    sudo cp services/backend.service /etc/systemd/system/
    sudo cp services/frontend.service /etc/systemd/system/
    sudo systemctl daemon-reload
    sudo systemctl enable --now backend.service
    sudo systemctl enable --now frontend.service

After setup: verify everything is running

# Check Nginx
sudo nginx -t && sudo systemctl status nginx

# Check your services
sudo systemctl status backend.service
sudo systemctl status frontend.service

# Check recent logs
sudo journalctl -u backend.service -n 50
sudo journalctl -u frontend.service -n 50