Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file added templates/nakama/assets/logo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added templates/nakama/assets/screenshot.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
47 changes: 47 additions & 0 deletions templates/nakama/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
import { Output, randomPassword, Services } from "~templates-utils";
import { Input } from "./meta";

export function generate(input: Input): Output {
const services: Services = [];
const databasePassword = randomPassword();
const databaseAddress = `postgres:${databasePassword}@$(PROJECT_NAME)_${input.appServiceName}-db:5432/$(PROJECT_NAME)`;

services.push({
type: "postgres",
data: {
serviceName: `${input.appServiceName}-db`,
password: databasePassword,
},
});

services.push({
type: "app",
data: {
serviceName: input.appServiceName,
source: {
type: "image",
image: input.appServiceImage,
},
domains: [
{
host: "$(EASYPANEL_DOMAIN)",
port: 7351,
},
],
mounts: [
{
type: "volume",
name: "data",
mountPath: "/nakama/data",
},
],
deploy: {
command:
`/bin/sh -ecx "/nakama/nakama migrate up --database.address ${databaseAddress} && ` +
`exec /nakama/nakama --name nakama1 --database.address ${databaseAddress} --logger.level DEBUG --session.token_expiry_sec 7200"`,
},
},
});

return { services };
}
68 changes: 68 additions & 0 deletions templates/nakama/meta.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
name: Nakama
description:
Nakama is an open-source server for social and real-time games and apps. It
provides user accounts, multiplayer, chat, leaderboards, tournaments, and
storage APIs, backed by PostgreSQL.
instructions:
After deployment, Nakama is available on your project domain at port 7351. The
template provisions a dedicated PostgreSQL service and runs Nakama database
migrations automatically before startup.
changeLog:
- date: 2026-04-29
description: First release
links:
- label: Website
url: https://heroiclabs.com/nakama/
- label: Documentation
url: https://heroiclabs.com/docs/nakama/
- label: GitHub
url: https://github.com/heroiclabs/nakama
contributors:
- name: Ahson Shaikh
url: https://github.com/Ahson-Shaikh
schema:
type: object
required:
- appServiceName
- appServiceImage
properties:
appServiceName:
type: string
title: App Service Name
default: nakama
appServiceImage:
type: string
title: App Service Image
default: registry.heroiclabs.com/heroiclabs/nakama:3.22.0
benefits:
- title: Game Backend Ready
description:
Includes core backend primitives such as accounts, sessions, storage,
chat, and multiplayer APIs with minimal setup.
- title: Built-In Database Provisioning
description:
Deploys PostgreSQL and Nakama together so you can start with a
production-style architecture quickly.
- title: Automatic Migration On Start
description:
Runs Nakama migrations before launching the main server process, reducing
manual setup work.
features:
- title: Real-Time Multiplayer Server
description:
Provides Nakama runtime for game sessions, matchmaking, social features,
and RPC endpoints.
- title: Persistent PostgreSQL Storage
description:
Stores data on a dedicated volume so database state survives restarts and
redeployments.
- title: Public Ports For API and Runtime
description:
Exposes standard Nakama ports for HTTP API, gRPC, and console-compatible
networking workflows.
tags:
- Game Server
- Realtime
- PostgreSQL
- Backend
- Multiplayer