• Dec. 2, 2025, 9:09 a.m.

    Overview

    Immich is a high-performance self-hosted backup solution for photos and videos, heavily inspired by Google Photos. While YunoHost has community scripts, running Immich via Docker Compose allows for greater control over updates and data management.

    This guide documents how I deployed Immich on my VPS (kupi.my) using a hybrid approach: the application runs in an isolated Docker container, while YunoHost handles the DNS and reverse proxying via the "Redirect" app.

    Prerequisites

    • OS: Debian 12 (Bookworm) / YunoHost environment.
    • Docker Engine: Installed and active.
    • Domain: immich.nulu.my configured in YunoHost.
    • Port: 2283 (Default Immich port, confirmed free).

    Installation Steps

    1. Directory Setup

    First, I created a dedicated directory to house the configuration files. It is best practice to keep this separate from system files.

    mkdir -p ~/immich-app
    cd ~/immich-app
    

    2. Download Configuration Files

    I retrieved the recommended docker-compose.yml and environment file from the official Immich repository:

    wget -O docker-compose.yml https://github.com/immich-app/immich/releases/latest/download/docker-compose.yml
    wget -O .env https://github.com/immich-app/immich/releases/latest/download/example.env
    

    3. Environment Configuration

    I modified the .env file to suit my local environment and security needs.

    nano .env
    

    Key Changes Made:

    • UPLOAD_LOCATION: Set to ./library (default).
    • DB_PASSWORD: Changed from the default to a secure, random string.
    • TZ: Set to Asia/Kuala_Lumpur to ensure timestamps match my local time.

    4. Deploying the Containers

    With the configuration ready, I spun up the stack. This pulls the necessary images (Server, Microservices, Machine Learning, Postgres, Redis) and starts them in the background.

    docker compose up -d
    

    Note: The initial pull can take a few minutes depending on the connection speed.

    Networking (YunoHost Reverse Proxy)

    Since the Docker container listens on 127.0.0.1:2283, it isn't accessible from the public internet yet. I used the YunoHost admin panel to bridge this.

    1. Logged into YunoHost Web Admin.
    2. Navigated to Applications > Install.
    3. Selected the Redirect app (sometimes labelled "Redirect to a local port").
    4. Configuration:
      • Domain: immich.nulu.my
      • Path: /
      • Type: Proxy (Crucial: Do not use Standard Redirect).
      • Destination: http://127.0.0.1:2283

    Post-Installation

    Once the redirect was installed, I accessed https://immich.nulu.my. The first screen prompted me to create the Admin Owner account.

    Updating Immich

    To update the instance in the future, I can simply run these commands inside the ~/immich-app directory:

    docker compose pull
    docker compose up -d
    

    References