Lucia-PostgreSQL

Lucia-PostgreSQL

Official

Docker app from Lucia's Repository

Overview

PostgreSQL storage for Lucia configuration, traces, and tasks. Before installing, run `docker network create lucia` in the Unraid terminal. Install this template before Lucia.

Unraid Community Apps

Unraid requires one XML template per container. Lucia therefore ships three linked templates:

Install

Create the user-defined bridge network before installing any template. Each template selects it through <Network>lucia</Network>.

Run this once in the Unraid terminal:

docker network create lucia
mkdir -p /mnt/cache/appdata/lucia/postgres-init /mnt/cache/appdata/lucia/models
curl -fsSL https://raw.githubusercontent.com/seiggy/lucia-dotnet/master/infra/unraid/init.sql \
  -o /mnt/cache/appdata/lucia/postgres-init/init.sql
chown -R 1100:1100 /mnt/cache/appdata/lucia/models

If your cache pool is not named cache, change the template paths before installing.

Install the templates in this order:

  1. Lucia-PostgreSQL. Set a long database password containing only letters and numbers.
  2. Lucia-Redis.
  3. Lucia. Replace CHANGE_ME in all three PostgreSQL connection strings with the same database password.

Open http://<unraid-ip>:7233 and complete the setup wizard.

PostgreSQL reads init.sql only when its data directory is empty. To repair an existing installation that started without it, create the missing databases before starting Lucia:

docker exec Lucia-PostgreSQL createdb -U lucia luciaconfig
docker exec Lucia-PostgreSQL createdb -U lucia luciatraces
docker exec Lucia-PostgreSQL createdb -U lucia luciatasks

Install Lucia-PostgreSQL on Unraid in a few clicks.

Find Lucia-PostgreSQL in Community Apps on your Unraid server, review the template, and click Install. Unraid handles the Docker app or plugin setup from the published template.

Open the Apps tab on your Unraid server Search Community Apps for Lucia-PostgreSQL Review the template variables and paths Click Install

Requirements

Before installing, run `docker network create lucia` in the Unraid terminal and install the supplied init.sql file as described in the Lucia Unraid readme.

Categories

Download Statistics

11,008,406,270
Total Downloads
138,421,369
This Month
132,804,652
Avg / Month

Total Downloads Over Time

Loading chart...

Related apps

Explore more like this

Explore all

Details

Repository
postgres:17
Last Updated2026-07-17
First Seen2021-04-29

Runtime arguments

Network
lucia
Shell
bash
Privileged
false
Extra Params
--restart=unless-stopped --health-cmd="pg_isready -U lucia -d postgres" --health-interval=10s --health-timeout=5s --health-retries=5

Template configuration

DataPathrw

PostgreSQL data. Use a direct cache-pool path, not an array path.

Target
/var/lib/postgresql/data
Default
/mnt/cache/appdata/lucia/postgres
InitializationPathro

Directory containing the supplied init.sql file. PostgreSQL reads it only when creating a new data directory.

Target
/docker-entrypoint-initdb.d
Default
/mnt/cache/appdata/lucia/postgres-init
Database userVariable

Lucia database user.

Target
POSTGRES_USER
Default
lucia
Database passwordVariable

Use the same password in all three Lucia PostgreSQL connection strings.

Target
POSTGRES_PASSWORD
Bootstrap databaseVariable

Bootstrap database used while init.sql creates Lucia's databases.

Target
POSTGRES_DB
Default
postgres
Initialization optionsVariable

Options used only when PostgreSQL creates a new data directory.

Target
POSTGRES_INITDB_ARGS
Default
--data-checksums
TimezoneVariable

Container timezone.

Target
TZ
Default
Etc/UTC
PortPorttcp

Optional host port for external database tools. Lucia does not need it.

Target
5432