Railway

Deploy Immich (Loopback Fixed)

Self-hosted Google Photos alt, full ML+Redis, loopback bug fixed

Deploy Immich (Loopback Fixed)

/var/lib/postgresql/data

Just deployed

/cache

Just deployed

/data

Deploy and Host Immich on Railway (Loopback-Bug Fixed)

Immich is a high-performance, self-hosted photo and video backup solution — a fully open-source alternative to Google Photos, with automatic mobile backup, facial recognition, object detection, smart search, and album sharing.

This template includes a fix for a real, currently-open upstream bug (immich-app/immich#26663) where the Immich server binds to loopback (127.0.0.1) regardless of the IMMICH_HOST setting, making it unreachable from outside its own container on standard Linux infrastructure (confirmed during testing: zero HTTP requests ever reached the app externally, even with IMMICH_HOST=0.0.0.0 explicitly set). This template's immich-server image adds a small socat relay sidecar that forwards external traffic to the loopback-bound app, verified working end-to-end — public URL, health checks, database, Redis, and machine learning all confirmed live.

About Hosting Immich

Hosting Immich gives you a complete self-managed photo library with automatic backup from the Immich mobile app, AI-powered facial recognition and object detection, duplicate detection, reverse geocoding for photo locations, and full album/sharing features — without handing your photos to a third-party cloud provider.

This template runs the full feature set (not a stripped-down "no-ML" variant): a dedicated machine-learning service for smart search and facial recognition, Redis for job queues and caching, and a Postgres database built with the VectorChord/pgvector extensions Immich requires for vector search — Railway's standard managed Postgres does not include these extensions, so this template deploys a purpose-built Postgres image instead.

Common Use Cases

  • Personal Photo/Video Backup: Automatic backup from the Immich mobile app (iOS/Android), replacing Google Photos or iCloud with a self-hosted library you fully control.

  • Family Photo Sharing: Shared albums and libraries across multiple user accounts, with granular sharing links.

  • AI-Powered Organization: Facial recognition, object detection, and smart natural-language search across your entire photo library.

  • Privacy-Focused Archival: Long-term photo/video storage without third-party scanning, ads, or unclear data retention policies.

Dependencies for Immich Hosting

Core Dependencies

  • PostgreSQL (VectorChord/pgvector) - Stores metadata, albums, and vector embeddings for smart search. Uses ghcr.io/immich-app/postgres:14-vectorchord0.4.3-pgvectors0.2.0 — not Railway's standard Postgres, since this image bundles the extensions Immich requires.
  • Redis - Job queue and caching layer for background processing (thumbnail generation, ML jobs, metadata extraction).
  • Immich Machine Learning - Dedicated inference service for facial recognition, smart search embeddings, and duplicate detection (ghcr.io/immich-app/immich-machine-learning:release).

Deployment Dependencies

Implementation Details

  • The immich-server service runs a custom image (built from the official one, publicly available) that adds a socat relay so the app is reachable externally — see the bug link above for background. No manual networking configuration is needed after deploy.
  • Machine learning inference runs on CPU only (no GPU access on Railway) — facial recognition and smart search work correctly but process more slowly than a GPU-accelerated self-hosted setup on your own hardware.
  • Uploaded photos/videos persist on a dedicated volume across redeploys.
  • To connect the Immich mobile app, use your Railway-generated domain as the server URL (no trailing slash, no /api suffix).

Why Deploy Immich on Railway?

Railway is a singular platform to deploy your infrastructure stack. Railway hosts your infrastructure so you don't have to deal with configuration, while letting you vertically scale it.

By deploying this template, you get the full Immich feature set — including machine learning and Redis, not a cut-down variant — with a genuine fix for a real reachability bug already applied and verified, so you can start backing up photos from the mobile app immediately after deploy.


Template Content

More templates in this category

View Template
Garage S3 Storage
Ultra-light S3 server: fast, open-source, plug-and-play.

PROJETOS
8
View Template
Redis
Self Host Latest Redis with Railway

2
View Template
EasyImg
Simple self-hostable Nuxt.js personal image hosting system.

Muhammad Bilal
0