Immich PostgreSQL
| Description / name | Input element |
|---|---|
| Container Registry | |
| Container Configuration Root Path | |
| Immich PostgreSQL Host Port | |
| Immich PostgreSQL /var/lib/postgresql/data Path |
PostgreSQL with pgvector and vectorchord extensions required by Immich for vector similarity search. Defaults to PostgreSQL 14 (:latest), PostgreSQL 18 available as :18.
| Port | 5432 |
| Registry | ghcr.io/daemonless/immich-postgres |
| Daemonless | daemonless/immich-postgres |
| Source | immich-app/immich |
| Website | immich.app |
Version Tags
| Tag | Description | Best For |
|---|---|---|
14 / latest |
Upstream Binary. Built from official release. | Most users. Matches Linux Docker behavior. |
18 |
Upstream Binary. Built from official release. | Alternative build. |
Root Privileges Required
Podman on FreeBSD currently requires root. All commands must be run as root (or via doas/sudo).
System V IPC Required
This application requires --annotation 'org.freebsd.jail.allow.sysvipc=true' for shared memory access (Requires patched ocijail).
Before deploying, ensure your host environment is ready. See the Quick Start Guide for host setup instructions.
Deployment
services:
immich-postgres:
image: ghcr.io/daemonless/immich-postgres:latest
container_name: immich-postgres
environment:
- POSTGRES_USER=postgres
- POSTGRES_PASSWORD=postgres
- POSTGRES_DB=immich
volumes:
- "/path/to/containers/immich-postgres/var/lib/postgresql/data:/var/lib/postgresql/data"
ports:
- 5432:5432
annotations:
org.freebsd.jail.allow.sysvipc: "true"
restart: unless-stopped
DIRECTOR_PROJECT=immich-postgres
POSTGRES_USER=postgres
POSTGRES_PASSWORD=postgres
POSTGRES_DB=immich
options:
- virtualnet: ':<random> default'
- nat:
services:
immich-postgres:
name: immich_postgres
options:
- container: 'boot args:--pull'
- template: !ENV '${PWD}/immich-postgres.conf'
oci:
user: root
environment:
- POSTGRES_USER: !ENV '${POSTGRES_USER}'
- POSTGRES_PASSWORD: !ENV '${POSTGRES_PASSWORD}'
- POSTGRES_DB: !ENV '${POSTGRES_DB}'
volumes:
- IMMICH_POSTGRES_VAR_LIB_POSTGRESQL_DATA_PATH: /var/lib/postgresql/data
volumes:
IMMICH_POSTGRES_VAR_LIB_POSTGRESQL_DATA_PATH:
device: '/path/to/containers/immich-postgres/var/lib/postgresql/data'
podman run -d --name immich-postgres \
-p 5432:5432 \
--annotation 'org.freebsd.jail.allow.sysvipc=true' \
-e POSTGRES_USER=postgres \
-e POSTGRES_PASSWORD=postgres \
-e POSTGRES_DB=immich \
-v /path/to/containers/immich-postgres/var/lib/postgresql/data:/var/lib/postgresql/data \
ghcr.io/daemonless/immich-postgres:latest
- name: Deploy immich-postgres
containers.podman.podman_container:
name: immich-postgres
image: ghcr.io/daemonless/immich-postgres:latest
state: started
restart_policy: always
env:
POSTGRES_USER: "postgres"
POSTGRES_PASSWORD: "postgres"
POSTGRES_DB: "immich"
ports:
- "5432:5432"
volumes:
- "/path/to/containers/immich-postgres/var/lib/postgresql/data:/var/lib/postgresql/data"
annotation:
org.freebsd.jail.allow.sysvipc: "true"
Interactive Configuration
Parameters
Environment Variables
| Variable | Default | Description |
|---|---|---|
POSTGRES_USER |
postgres |
Database superuser (default: postgres) |
POSTGRES_PASSWORD |
postgres |
Database password (default: postgres) |
POSTGRES_DB |
immich |
Database name (default: immich) |
Volumes
| Path | Description |
|---|---|
/var/lib/postgresql/data |
Database data directory |
Ports
| Port | Protocol | Description |
|---|---|---|
5432 |
TCP | PostgreSQL Port |
This image is part of the Immich Stack.
PostgreSQL version: :latest and :14 use PostgreSQL 14. :18 uses PostgreSQL 18.
New installations should consider :18. If you are migrating an existing Immich instance,
stay on :14 — PostgreSQL major version upgrades require a full pg_dumpall and restore.
The default :latest tag will follow whatever version Immich recommends upstream.
PostgreSQL requires allow.sysvipc for shared memory. Create immich-postgres.conf alongside appjail-director.yml:
exec.start: "/bin/sh /etc/rc"
exec.stop: "/bin/sh /etc/rc.shutdown jail"
mount.devfs
persist
allow.sysvipc
Implementation Details
- Architectures: amd64
- User:
postgres(UID/GID set via PUID/PGID). Defaults to1000:1000. - Base: Built on
ghcr.io/daemonless/base(FreeBSD 15.0).
Need help? Join our Discord community.