Getting started
Installing the controller
The controller is the panel. Install it once, on Windows, on Linux or in Docker, then finish the configuration in your browser.
Packages
| File | What |
|---|---|
NGCP-Setup-X.Y.Z.exe |
Windows setup: the panel, game servers or both, in one installer (recommended on Windows) |
ngcp-appliance-X.Y.Z-installer.iso, .vhdx, .ova |
Linux appliance: Ubuntu 24.04 with NGCP ready to go (The Linux appliance) |
ngcp-controller-X.Y.Z-x64.msi |
Controller for Windows (includes PostgreSQL 16) |
ngcp-controller_X.Y.Z_amd64.deb, ..._arm64.deb |
Controller for Debian / Ubuntu |
ngcp-controller-X.Y.Z-1.x86_64.rpm, ...aarch64.rpm |
Controller for RHEL / Rocky / Alma |
ngcp-agent-... (msi, deb, rpm) |
The node agent (Adding a node) |
SHA256SUMS |
Checksums of every file |
The controller packages carry every agent package and agent build. Once the panel runs, nodes install the agent straight from it, and the panel can update its agents without internet access.
Check a download before installing:
sha256sum -c SHA256SUMS --ignore-missing
Get-FileHash .\ngcp-controller-X.Y.Z-x64.msi -Algorithm SHA256
Install on Windows
With NGCP Setup (recommended)
NGCP-Setup-X.Y.Z.exe installs everything a Windows server needs.
Run it as an administrator (SmartScreen warns because it is not code-signed yet) and choose what
this server does:
| Choice | Installs | Next |
|---|---|---|
| Panel and Game servers (both ticked, the default) | Controller with PostgreSQL, and the agent | The setup page opens; leave This server runs game servers too ticked and this server joins as a game node by itself |
| Panel only | Controller with PostgreSQL | The setup page opens; add game servers on other computers later |
| Game servers only | The agent | Enter the panel’s address, enrollment token and CA hash under Options (from the panel: Nodes, Add a node), or join later |
It appears once in Apps / Programs and Features as NGCP; Repair and Uninstall work
on both parts. Uninstalling keeps the panel’s database and settings in C:\ProgramData\NGCP.
Unattended:
.\NGCP-Setup-X.Y.Z.exe /quiet # panel + game servers
.\NGCP-Setup-X.Y.Z.exe /quiet InstallAgent=0 # panel only
.\NGCP-Setup-X.Y.Z.exe /quiet InstallController=0 ControllerUrl=https://panel.example.com EnrollToken=ngcpe_... CaHash=sha256:...
Add /log setup.log for a log file (the enrollment token is never written to it).
With the controller MSI
- Run
ngcp-controller-X.Y.Z-x64.msias an administrator. SmartScreen warns because the MSI is not code-signed yet. - The installer:
- installs the program to
C:\Program Files\NGCP Controller; - keeps configuration in
C:\ProgramData\NGCP\Controller(readable only by SYSTEM and Administrators); - adds the Windows service NGCP Controller (
NGCPController); - opens TCP 8080 (web) and 8443 (agents) in Windows Firewall.
- installs the program to
- Leave Open the setup page (http://localhost:8080/setup) ticked on the last page and continue with the setup.
For a silent install:
msiexec /i ngcp-controller-X.Y.Z-x64.msi /qn
Install on Linux
# Debian / Ubuntu (pulls in PostgreSQL)
sudo apt install ./ngcp-controller_X.Y.Z_amd64.deb
# RHEL / Rocky / Alma (pulls in postgresql-server)
sudo dnf install ./ngcp-controller-X.Y.Z-1.x86_64.rpm
The package:
- creates the system user
ngcpand the systemd unitngcp-controller(hardened: read-only system, writable only/etc/ngcpand/var/lib/ngcp-controller); - starts PostgreSQL if it is installed locally and creates the role and database
ngcp, reached over the Unix socket with peer authentication (no password anywhere); - puts the configuration in
/etc/ngcp/controller.env(mode 0600, ownerngcp).
If a firewall is active, open TCP 8080 and 8443, for example:
sudo ufw allow 8080/tcp
sudo ufw allow 8443/tcp
# or
sudo firewall-cmd --permanent --add-port=8080/tcp --add-port=8443/tcp && sudo firewall-cmd --reload
Install with Docker
The repository’s deploy/docker folder holds an image definition and a compose file that runs
the controller with PostgreSQL 16. This setup has not yet been run on a Docker host in
testing.
cd deploy/docker
echo "POSTGRES_PASSWORD=$(openssl rand -hex 24)" > .env
docker compose up -d --build
The container starts in setup mode with its configuration on the volume /etc/ngcp. In the
setup choose Existing database and enter:
postgres://ngcp:<POSTGRES_PASSWORD>@db:5432/ngcp?sslmode=disable
Agents are not run in Docker: install them on the game-server machines.
Finish the setup in a browser
Until the setup is done the controller serves only the setup page and its API.
-
Open
http://<server>:8080/setup.- On the server itself no token is needed.
- From another computer the page asks for the setup token:
Install Where the token is Windows C:\ProgramData\NGCP\Controller\setup-token.txtLinux sudo ngcp-controller setup-urlprints the address with the token (orsudo cat /etc/ngcp/setup-token.txt)Docker docker compose exec controller cat /etc/ngcp/setup-token.txt
-
Database: Built-in or Existing.
- Built-in on Windows creates a PostgreSQL cluster in
C:\ProgramData\NGCP\Controller\postgres\data, listening on127.0.0.1only (first free port from 5433), run by the service NGCPPostgreSQL as NetworkService with a random password. - Built-in on Linux uses the local database the package prepared.
- Existing: a URL such as
postgres://ngcp:[email protected]:5432/ngcp. The page tests the connection first.
- Built-in on Windows creates a PostgreSQL cluster in
-
Administrator: user name, e-mail and password of the first SuperAdmin. Turn on two-factor sign-in right after the first sign-in.
-
Address: the public URL browsers and nodes use, for example
https://panel.example.comorhttp://203.0.113.10:8080, and, if different, the agent address (host:8443). By default the agent address is the public URL’s host name with port 8443. Nodes must be able to resolve and reach both. -
TLS: see below.
-
Game servers on this server (shown only when the NGCP agent is installed on the same computer, as with NGCP Setup’s default or the appliance’s Panel and game servers): leave This server runs game servers too ticked, optionally with a node name (default: the computer name). The setup leaves a one-time join file for the agent (
local-node.jsonin the configuration folder, valid for 24 hours); the agent joins within seconds, deletes it and appears under Nodes in the datacenter Default. -
Finish. The controller writes its configuration and a new master key, creates the database schema, the SuperAdmin and a datacenter named Default, and switches to normal operation without a restart. Sign in at the public URL.
The setup token is deleted when the setup finishes, and the setup API answers 404 afterwards. If the setup fails halfway you can run it again; it keeps what it already created.
TLS and reverse proxies
The setup offers three TLS modes:
| Mode | Use it when | Public URL |
|---|---|---|
| None | The panel is on a trusted network, or TLS ends at a reverse proxy in front of it | http://..., or the proxy’s https://... |
| Certificate files | You have a certificate and key (PEM) on the server | https://... |
| Self-signed | Testing; browsers warn | https://... |
Certificate files are set with NGCP_TLS_CERT_FILE and NGCP_TLS_KEY_FILE. On Linux the files
must be readable by the user ngcp. Automatic certificates (ACME / Let’s Encrypt) are not
supported yet. The AgentLink port (8443) always uses its own certificates from the panel’s
internal CA, whatever you choose here.
Behind a reverse proxy:
- Set TLS mode None and enter the proxy’s
https://URL as the public URL; the session cookie is then always sent with the Secure flag. - Forward WebSocket upgrades for
/ws. - Allow request bodies of at least 64 MiB (upload chunks), and long timeouts for uploads.
- Tell the controller which proxy addresses to trust for
X-Forwarded-For, so sign-in limits and the admin IP allow-list see real client addresses:NGCP_TRUSTED_PROXIES=127.0.0.1/32. - Do not proxy port 8443; agents need a direct TCP connection to it.
- Finish the setup before you put a proxy on the same machine in front of the panel: requests from the server itself skip the setup token.
controller.env reference
Every setting can come from the environment or from controller.env. The environment wins.
The file uses KEY=value lines; # starts a comment.
| Setting | Default | Meaning |
|---|---|---|
NGCP_DATABASE_URL |
(set by the setup) | PostgreSQL URL. Without it, and with the config file present, the controller serves the setup. |
NGCP_MASTER_KEY_FILE |
(set by the setup) | File with the master key that seals secrets. Back it up. |
NGCP_MASTER_KEY |
The master key itself instead of a file. | |
NGCP_LISTEN |
127.0.0.1:8080 (packages: :8080) |
HTTP listen address. |
NGCP_PUBLIC_URL |
http://<listen> |
URL browsers and agents use. |
NGCP_GRPC_LISTEN |
127.0.0.1:8443 (packages: :8443) |
AgentLink listen address. |
NGCP_GRPC_ADVERTISE |
from the listen address | host:port agents dial; also put into the AgentLink certificate. |
NGCP_GRPC_HOSTNAMES |
Extra names / IPs for the AgentLink certificate, comma-separated. | |
NGCP_TLS_CERT_FILE, NGCP_TLS_KEY_FILE |
Serve HTTPS with these PEM files (both or neither). | |
NGCP_COOKIE_SECURE |
auto |
auto, always or never (development only) for the session cookie’s Secure flag. |
NGCP_TRUSTED_PROXIES |
CIDRs whose X-Forwarded-For is trusted. |
|
NGCP_WS_ORIGINS |
Extra origins allowed on /ws (development servers). |
|
NGCP_AUTO_MIGRATE |
true after setup |
Apply database migrations at start. Without it the controller refuses to start on an old schema. |
NGCP_LOG_LEVEL |
info |
debug, info, warn, error. |
NGCP_LOG_FILE |
Windows: controller.log |
Also log to this file (relative to the config folder). Rotated at 20 MB. |
NGCP_AGENT_RELEASES_DIR |
the package’s share/agent-releases |
Agent builds for self-update. |
NGCP_PACKAGES_DIR |
the package’s share/packages |
Agent packages served to the one-line installers. |
NGCP_CONFIG |
Windows C:\ProgramData\NGCP\Controller\controller.env, Linux /etc/ngcp/controller.env |
Where the config file is (same as -config). |
After changing the file, restart the controller:
sudo systemctl restart ngcp-controller
Restart-Service NGCPController
Files and folders
| Windows | Linux | |
|---|---|---|
| Program | C:\Program Files\NGCP Controller |
/usr/bin/ngcp-controller, /usr/share/ngcp |
| Configuration, master key, self-signed certificate | C:\ProgramData\NGCP\Controller |
/etc/ngcp |
| Built-in database | C:\ProgramData\NGCP\Controller\postgres\data |
the distribution’s PostgreSQL |
| Log | C:\ProgramData\NGCP\Controller\controller.log |
journalctl -u ngcp-controller |
Without the packages
The bare binaries still work. Create a key, migrate, create an administrator and serve:
export NGCP_MASTER_KEY="$(ngcpctl gen-master-key)"
export NGCP_DATABASE_URL="postgres://ngcp:[email protected]:5432/ngcp"
ngcpctl migrate
ngcpctl create-admin -email [email protected] -username admin
ngcp-controller serve -listen 0.0.0.0:8080 -public-url https://panel.example.com \
-grpc-listen 0.0.0.0:8443 -grpc-advertise panel.example.com:8443
Keep the master key: everything sealed with it is unreadable without it. See Command line.
Next: add a node.