Environment variables
What tells a server who it is, and where server-service is. They are environment variables rather than settings so that one
configuration can be shared by every server of a type (in a container image, for instance).
Game servers and proxy
| Variable | Required | What it is |
|---|---|---|
SERVER_ID | Yes | Unique id of this server, for example gens-1. It owns the player locks and is shown by %GrayCorePaper_server_id%. |
SERVER_TYPE | Yes | Its type, for example gens. Servers of the same type are interchangeable for routing. The proxy uses velocity. |
RPC_SERVER_SERVICE_ENDPOINT | Yes | host:port of the gRPC port of server-service. |
RPC_SERVER_SERVICE_API_KEY | Yes | The key server-service expects (its GRPC_API_KEY). |
SERVER_IP | Game servers | The address the proxy uses to reach this server. |
NODE_NAME | No | The machine or node the server runs on, reported to server-service. |
A game server refuses to start when one of the required ones is missing, rather than starting half configured.
server-service
| Variable | What it is |
|---|---|
GRPC_API_KEY | The key the game servers and proxies must present. |
Development stack
dev/docker-compose.yml sets all of the above with working defaults. Copy dev/.env.example to dev/.env to change the
passwords and keys, see Local development stack.