Self-host Logto with Levelrail

Modern, developer-first customer identity: sign-in experiences, social login, and OIDC without the plumbing.

  • Authorlogto-io
  • LicenceMPL-2.0
  • Memory1 GiB
  • Archarm64
  • Services2

How to self-host Logto

  1. Pull the images

    2 images are pulled on your server.

    Show images
    • postgres:16-alpine
    • svhd/logto:1.43.0
  2. Create the app

    2 services start in a single Compose app, with 1 named volume mount for your data, on ports 3001, 3002.

  3. Fill in the secrets

    2 secrets are generated and stored encrypted, 5 settings are preset, you do not have to fill in anything.

  4. Open it

    Without a domain the app gets an sslip.io address; add --domain SERVICE=HOST to use your own.

Logto requirements

Memory
About 1 GiB
Architectures
amd64 image published, arm64 image published
Ports
3001, 3002
Domain
Optional, an sslip.io address is used without one
Settings
none to fill in
License
MPL-2.0, copyleft license
  • Listed. It is in the catalog but not verified. Back up the data volume before changing an image tag.
  • Host ports. It publishes ports 3001, 3002 on the host, so open them in the VPS firewall only if you want that.

Install Levelrail first

On a server with Levelrail running, run the command above, or open the dashboard: Apps, New app, Browse templates, then Logto. New to Levelrail? Install it on a fresh VPS first.

docker pull ghcr.io/glincker/levelrail:latest

Then levelrail-cli login --device. See Getting started and the Logto docs page.

Deploy Logto your way

Every format below deploys the same pinned images. Pick the one that fits how you work.

Deploy Logto from the CLI

levelrail-cli templates deploy logto --name my-logto

Deploy Logto with the API

Create a token in the dashboard first. This one-click route deploys it as a trial app you can keep or remove.

curl -X POST -H "Authorization: Bearer $TOKEN" \
  https://levelrail.example.com/api/v1/service-templates/logto/deploy

Logto configuration

Logto services

ServiceImagePortsVolumes
db postgres:16-alpine none logto_db_data -> /var/lib/postgresql/data
logto svhd/logto:1.43.0 3001, 3002 none

Logto environment variables

VariableServiceValue
POSTGRES_DB db Preset by the template
POSTGRES_PASSWORD db Generated at deploy
POSTGRES_USER db Preset by the template
ADMIN_ENDPOINT logto Preset by the template
DB_URL logto Generated at deploy
ENDPOINT logto Preset by the template
TRUST_PROXY_HEADER logto Preset by the template

Ports and volumes

Ports
3001, 3002
Volumes
1 named mount: logto_db_data -> /var/lib/postgresql/data

Logto FAQ

How much memory does Logto need?

The catalog lists about 1 GiB of memory for Logto across its 2 services.

Does Logto run on arm64?

For Logto, an arm64 image is published; amd64 is image published.

What licence is Logto under?

Logto is licensed under MPL-2.0, which is copyleft, so changes you distribute must be shared under the same terms.

Does Logto need configuration before it starts?

No. The template fills in its own defaults and generates secrets at deploy time.

Which database does Logto bundle?

The template includes Postgres, running as its own service.

Which ports does Logto use?

Logto listens on ports 3001 and 3002 inside the stack.

Where does Logto keep its data?

In a named volume: logto_db_data mounted at /var/lib/postgresql/data.

Can I deploy Logto on Dokploy or Dokku?

The services and pinned images on this page can be run on any Docker host. The public Dokploy templates list has an entry with the id logto for this app, so check that entry as well. Dokku deploys container images with its own commands, so the pinned image postgres:16-alpine, svhd/logto:1.43.0 is what you deploy there.

levelrail-cli templates deploy logto --name my-logto