[BUG] Shared link is broken #1256

Closed
opened 2026-02-05 01:02:42 +03:00 by OVERLORD · 4 comments
Owner

Originally created by @Opwi on GitHub (Aug 19, 2023).

The bug

I upgrade to v1.74.0 and when I open a shared link on web browser (computer or mobile) I cannot open any pictures in the shared album. When I try to open it, I receive this response:

{
    "statusCode": 401,
    "message": "Authentication required",
    "error": "Unauthorized"
}

I downgrade to v1.73.0 and everything working well. Furthermore, I suspect the issue come from the v1.74.0 because I don't change anything between v1.73.0 and v1.74.0.

The OS that Immich Server is running on

Debian 12.1

Version of Immich Server

v1.74.0

Version of Immich Mobile App

v1.73.0

Platform with the issue

  • Server
  • Web
  • Mobile

Your docker-compose.yml content

version: "3.8"

services:
  immich-server:
    container_name: immich_server
    image: ghcr.io/immich-app/immich-server:${IMMICH_VERSION:-release}
    command: [ "start.sh", "immich" ]
    volumes:
      - ${UPLOAD_LOCATION}:/usr/src/app/upload
    env_file:
      - .env
    depends_on:
      - redis
      - database
      - typesense
    restart: unless-stopped

  immich-microservices:
    container_name: immich_microservices
    image: ghcr.io/immich-app/immich-server:${IMMICH_VERSION:-release}
    command: [ "start.sh", "microservices" ]
    volumes:
      - ${UPLOAD_LOCATION}:/usr/src/app/upload
    env_file:
      - .env
    depends_on:
      - redis
      - database
      - typesense
    restart: unless-stopped

  immich-machine-learning:
    container_name: immich_machine_learning
    image: ghcr.io/immich-app/immich-machine-learning:${IMMICH_VERSION:-release}
    volumes:
      - model-cache:/cache
    env_file:
      - .env
    restart: unless-stopped

  immich-web:
    container_name: immich_web
    image: ghcr.io/immich-app/immich-web:${IMMICH_VERSION:-release}
    env_file:
      - .env
    restart: unless-stopped

  typesense:
    container_name: immich_typesense
    image: typesense/typesense:0.24.1@sha256:9bcff2b829f12074426ca044b56160ca9d777a0c488303469143dd9f8259d4dd
    environment:
      - TYPESENSE_API_KEY=${TYPESENSE_API_KEY}
      - TYPESENSE_DATA_DIR=/data
    volumes:
      - tsdata:/data
    restart: unless-stopped

  redis:
    container_name: immich_redis
    image: redis:6.2-alpine@sha256:70a7a5b641117670beae0d80658430853896b5ef269ccf00d1827427e3263fa3
    restart: unless-stopped

  database:
    container_name: immich_postgres
    image: postgres:14-alpine@sha256:28407a9961e76f2d285dc6991e8e48893503cc3836a4755bbc2d40bcc272a441
    env_file:
      - .env
    environment:
      POSTGRES_PASSWORD: ${DB_PASSWORD}
      POSTGRES_USER: ${DB_USERNAME}
      POSTGRES_DB: ${DB_DATABASE_NAME}
      PG_DATA: /var/lib/postgresql/data
    volumes:
      - pgdata:/var/lib/postgresql/data
    restart: unless-stopped

  immich-proxy:
    container_name: immich_proxy
    image: ghcr.io/immich-app/immich-proxy:${IMMICH_VERSION:-release}
    environment:
      # Make sure these values get passed through from the env file
      - IMMICH_SERVER_URL
      - IMMICH_WEB_URL
    ports:
      - 2283:8080
    depends_on:
      - immich-server
      - immich-web
    restart: unless-stopped

volumes:
  pgdata:
  model-cache:
  tsdata:

Your .env content

###################################################################################
# Database
###################################################################################

DB_HOSTNAME=immich_postgres
DB_USERNAME=postgres
DB_PASSWORD="secret_password"
DB_DATABASE_NAME=immich


###################################################################################
# Redis
###################################################################################

REDIS_HOSTNAME=immich_redis


###################################################################################
# Upload File Location
#
# This is the location where uploaded files are stored.
###################################################################################

UPLOAD_LOCATION=/home/docker/immich


###################################################################################
# Typesense
###################################################################################
TYPESENSE_API_KEY="secret"


IMMICH_WEB_URL=http://immich-web:3000
IMMICH_SERVER_URL=http://immich-server:3001
IMMICH_MACHINE_LEARNING_URL=http://immich-machine-learning:3003

Reproduction steps

1.Create a shared link
2.Go in private navigation
3.Try to open any pictures in the shared album.

Additional information

No response

Originally created by @Opwi on GitHub (Aug 19, 2023). ### The bug I upgrade to v1.74.0 and when I open a shared link on web browser (computer or mobile) I cannot open any pictures in the shared album. When I try to open it, I receive this response: ``` { "statusCode": 401, "message": "Authentication required", "error": "Unauthorized" } ``` I downgrade to v1.73.0 and everything working well. Furthermore, I suspect the issue come from the v1.74.0 because I don't change anything between v1.73.0 and v1.74.0. ### The OS that Immich Server is running on Debian 12.1 ### Version of Immich Server v1.74.0 ### Version of Immich Mobile App v1.73.0 ### Platform with the issue - [ ] Server - [X] Web - [ ] Mobile ### Your docker-compose.yml content ```YAML version: "3.8" services: immich-server: container_name: immich_server image: ghcr.io/immich-app/immich-server:${IMMICH_VERSION:-release} command: [ "start.sh", "immich" ] volumes: - ${UPLOAD_LOCATION}:/usr/src/app/upload env_file: - .env depends_on: - redis - database - typesense restart: unless-stopped immich-microservices: container_name: immich_microservices image: ghcr.io/immich-app/immich-server:${IMMICH_VERSION:-release} command: [ "start.sh", "microservices" ] volumes: - ${UPLOAD_LOCATION}:/usr/src/app/upload env_file: - .env depends_on: - redis - database - typesense restart: unless-stopped immich-machine-learning: container_name: immich_machine_learning image: ghcr.io/immich-app/immich-machine-learning:${IMMICH_VERSION:-release} volumes: - model-cache:/cache env_file: - .env restart: unless-stopped immich-web: container_name: immich_web image: ghcr.io/immich-app/immich-web:${IMMICH_VERSION:-release} env_file: - .env restart: unless-stopped typesense: container_name: immich_typesense image: typesense/typesense:0.24.1@sha256:9bcff2b829f12074426ca044b56160ca9d777a0c488303469143dd9f8259d4dd environment: - TYPESENSE_API_KEY=${TYPESENSE_API_KEY} - TYPESENSE_DATA_DIR=/data volumes: - tsdata:/data restart: unless-stopped redis: container_name: immich_redis image: redis:6.2-alpine@sha256:70a7a5b641117670beae0d80658430853896b5ef269ccf00d1827427e3263fa3 restart: unless-stopped database: container_name: immich_postgres image: postgres:14-alpine@sha256:28407a9961e76f2d285dc6991e8e48893503cc3836a4755bbc2d40bcc272a441 env_file: - .env environment: POSTGRES_PASSWORD: ${DB_PASSWORD} POSTGRES_USER: ${DB_USERNAME} POSTGRES_DB: ${DB_DATABASE_NAME} PG_DATA: /var/lib/postgresql/data volumes: - pgdata:/var/lib/postgresql/data restart: unless-stopped immich-proxy: container_name: immich_proxy image: ghcr.io/immich-app/immich-proxy:${IMMICH_VERSION:-release} environment: # Make sure these values get passed through from the env file - IMMICH_SERVER_URL - IMMICH_WEB_URL ports: - 2283:8080 depends_on: - immich-server - immich-web restart: unless-stopped volumes: pgdata: model-cache: tsdata: ``` ### Your .env content ```Shell ################################################################################### # Database ################################################################################### DB_HOSTNAME=immich_postgres DB_USERNAME=postgres DB_PASSWORD="secret_password" DB_DATABASE_NAME=immich ################################################################################### # Redis ################################################################################### REDIS_HOSTNAME=immich_redis ################################################################################### # Upload File Location # # This is the location where uploaded files are stored. ################################################################################### UPLOAD_LOCATION=/home/docker/immich ################################################################################### # Typesense ################################################################################### TYPESENSE_API_KEY="secret" IMMICH_WEB_URL=http://immich-web:3000 IMMICH_SERVER_URL=http://immich-server:3001 IMMICH_MACHINE_LEARNING_URL=http://immich-machine-learning:3003 ``` ### Reproduction steps ```bash 1.Create a shared link 2.Go in private navigation 3.Try to open any pictures in the shared album. ``` ### Additional information _No response_
Author
Owner

@alextran1502 commented on GitHub (Aug 21, 2023):

Hello, do you mind record a video from creating and accessing the share link that show the error message so I understand where the bug is at?

@alextran1502 commented on GitHub (Aug 21, 2023): Hello, do you mind record a video from creating and accessing the share link that show the error message so I understand where the bug is at?
Author
Owner

@akoyaxd commented on GitHub (Aug 21, 2023):

I face the same issue.
When I open a shared link without being logged in, I can not open the large preview of that asset, when I click it. This affacts videos and images.

The video preview on hovering over the asset works tough.

This is the http error I get.

{
    "statusCode": 401,
    "message": "Authentication required",
    "error": "Unauthorized"
}
@akoyaxd commented on GitHub (Aug 21, 2023): I face the same issue. When I open a shared link without being logged in, I can not open the large preview of that asset, when I click it. This affacts videos and images. The video preview on hovering over the asset works tough. This is the http error I get. ``` { "statusCode": 401, "message": "Authentication required", "error": "Unauthorized" }
Author
Owner

@ghost commented on GitHub (Aug 21, 2023):

I face the same issue. When I open a shared link without being logged in, I can not open the large preview of that asset, when I click it. This affacts videos and images.

The video preview on hovering over the asset works tough.

This is the http error I get.

{
    "statusCode": 401,
    "message": "Authentication required",
    "error": "Unauthorized"
}

Same issue for me

@ghost commented on GitHub (Aug 21, 2023): > I face the same issue. When I open a shared link without being logged in, I can not open the large preview of that asset, when I click it. This affacts videos and images. > > The video preview on hovering over the asset works tough. > > This is the http error I get. > > ``` > { > "statusCode": 401, > "message": "Authentication required", > "error": "Unauthorized" > } > ``` Same issue for me
Author
Owner

@Opwi commented on GitHub (Aug 21, 2023):

Hello, do you mind record a video from creating and accessing the share link that show the error message so I understand where the bug is at?

You can find the record video here @alextran1502 : https://youtu.be/Yw4XwjFmHdE

@Opwi commented on GitHub (Aug 21, 2023): > Hello, do you mind record a video from creating and accessing the share link that show the error message so I understand where the bug is at? You can find the record video here @alextran1502 : https://youtu.be/Yw4XwjFmHdE
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: immich-app/immich#1256