Install with Docker
Both methods run the same docker-compose.yml. The installer also generates real secrets and verifies the configuration before it starts anything, so use it unless you have a reason not to.
-
Run the installer
Terminal window curl -fsSL https://railhook.io/install.sh | bashIt checks Docker, Compose, memory, disk and the port. It then writes
~/railhook, which contains adocker-compose.ymlpinned to the latest release, a.envwith generated secrets, and arailhookhelper script. Finally it starts the stack and waits until the API answers. The first start runs the database migrations and creates the Kafka topics, so it can take a few minutes. -
Open the dashboard
Go to
http://localhost(orhttp://<server-ip>; add:<port>if you installed with--port) and register. With no mail server configured, the account is active immediately. -
Back up
.envWEBHOOK_ENCRYPTION_KEYandWEBHOOK_ENCRYPTION_SALTin it encrypt every endpoint secret in the database. A database backup restored without this file gives you rows nothing can read.
Installer options
Section titled “Installer options”Pass options through the pipe with bash -s --:
curl -fsSL https://railhook.io/install.sh | bash -s -- --dir /opt/railhook --port 8080| Option | Effect |
|---|---|
--dir <path> |
Where to install. Default ~/railhook |
--version <tag> |
Release to pin, v2.12.0 or newer. Default: the latest release |
--port <port> |
The one published port. Default 80, or 8080 with --behind-proxy |
--domain <host> |
Serve on this domain over HTTPS. See Domain and HTTPS |
--behind-proxy |
With --domain: your own reverse proxy terminates TLS, and the dashboard listens on 127.0.0.1 for it |
--email <address> |
Where Let’s Encrypt sends expiry warnings |
--no-start |
Write the files, start nothing |
--yes |
Do not ask before reusing a non-empty directory |
--check |
Run the system and configuration checks only |
--uninstall |
Stop the stack and remove the containers. Data volumes are kept |
--purge |
Uninstall and delete the data volumes too |
Day-to-day commands
Section titled “Day-to-day commands”Run these from the install directory:
| Command | Does |
|---|---|
./railhook status |
Lists the containers and their health |
./railhook logs [service] |
Follows logs, for example ./railhook logs api |
./railhook start / stop / restart |
Starts, stops or restarts the stack |
./railhook upgrade [version] |
Backs up, then upgrades. See Upgrade and backup |
./railhook backup |
Writes a database dump into the directory |
./railhook doctor |
Re-runs every check against the files on disk |
Any other argument is passed straight to Docker Compose, so ./railhook ps or ./railhook up -d work as you would expect.
-
Download the Compose file and the settings catalogue
Terminal window mkdir railhook && cd railhookcurl -fsSLO https://raw.githubusercontent.com/vadymkykalo/railhook/main/docker-compose.ymlcurl -fsSL https://raw.githubusercontent.com/vadymkykalo/railhook/main/.env.dist -o .env -
Replace the public secrets
The values in
.env.distare public. Generate your own for each of these:.env WEBHOOK_ENCRYPTION_KEY= # openssl rand -base64 32WEBHOOK_ENCRYPTION_SALT= # openssl rand -base64 16JWT_SECRET= # openssl rand -base64 48POSTGRES_PASSWORD= # must equal DB_PASSWORDDB_PASSWORD=REDIS_PASSWORD=Set
APP_BASE_URLandCORS_ALLOWED_ORIGINSto the URL people will open.RAILHOOK_PORTin this file is8080. -
Start it with the embedded database
Terminal window COMPOSE_PROFILES=embedded-db docker compose up -d -
Check it
Terminal window curl -f http://localhost:8080/actuator/health/livenesscurl -o /dev/null -w '%{http_code}\n' http://localhost:8080/api/v1/projects # expect 401