rename environment variable to IMMICH_API_URL_EXTERNAL
This commit is contained in:
+3
-3
@@ -78,20 +78,20 @@ IMMICH_SERVER_URL=http://immich-server:3001
|
|||||||
IMMICH_MACHINE_LEARNING_URL=http://immich-machine-learning:3003
|
IMMICH_MACHINE_LEARNING_URL=http://immich-machine-learning:3003
|
||||||
|
|
||||||
####################################################################################
|
####################################################################################
|
||||||
# Alternative Public Server Address - Optional
|
# Alternative API's External Address - Optional
|
||||||
#
|
#
|
||||||
# This is an advanced feature used to control the public server endpoint returned to clients during Well-known discovery.
|
# This is an advanced feature used to control the public server endpoint returned to clients during Well-known discovery.
|
||||||
# You should only use this if the API server is exposed publicly via a custom host/path.
|
# You should only use this if the API server is exposed publicly via a custom host/path.
|
||||||
# Examples: http://localhost:3001, http://immich-api.example.com, etc
|
# Examples: http://localhost:3001, http://immich-api.example.com, etc
|
||||||
####################################################################################
|
####################################################################################
|
||||||
|
|
||||||
IMMICH_SERVER_PUBLIC_URL=http://localhost:3001
|
IMMICH_API_URL_EXTERNAL=http://localhost:3001
|
||||||
|
|
||||||
####################################################################################
|
####################################################################################
|
||||||
# API Cors Allowed Origins - Optional
|
# API Cors Allowed Origins - Optional
|
||||||
#
|
#
|
||||||
# This is required if the API is served from a different domain than the website.
|
# This is required if the API is served from a different domain than the website.
|
||||||
# For example, if IMMICH_SERVER_PUBLIC_URL is set to a full URL.
|
# For example, if IMMICH_API_URL_EXTERNAL is set to a full URL.
|
||||||
####################################################################################
|
####################################################################################
|
||||||
|
|
||||||
ALLOW_CORS_ORIGIN=http://localhost:2283
|
ALLOW_CORS_ORIGIN=http://localhost:2283
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
version: '3.8'
|
version: "3.8"
|
||||||
|
|
||||||
services:
|
services:
|
||||||
immich-server:
|
immich-server:
|
||||||
@@ -76,7 +76,7 @@ services:
|
|||||||
environment:
|
environment:
|
||||||
# Rename these values for svelte public interface
|
# Rename these values for svelte public interface
|
||||||
- PUBLIC_IMMICH_SERVER_URL=${IMMICH_SERVER_URL}
|
- PUBLIC_IMMICH_SERVER_URL=${IMMICH_SERVER_URL}
|
||||||
- PUBLIC_IMMICH_SERVER_PUBLIC_URL=${IMMICH_SERVER_PUBLIC_URL}
|
- PUBLIC_IMMICH_API_URL_EXTERNAL=${IMMICH_API_URL_EXTERNAL}
|
||||||
ports:
|
ports:
|
||||||
- 3000:3000
|
- 3000:3000
|
||||||
- 24678:24678
|
- 24678:24678
|
||||||
|
|||||||
@@ -54,7 +54,7 @@ services:
|
|||||||
environment:
|
environment:
|
||||||
# Rename these values for svelte public interface
|
# Rename these values for svelte public interface
|
||||||
- PUBLIC_IMMICH_SERVER_URL=${IMMICH_SERVER_URL}
|
- PUBLIC_IMMICH_SERVER_URL=${IMMICH_SERVER_URL}
|
||||||
- PUBLIC_IMMICH_SERVER_PUBLIC_URL=${IMMICH_SERVER_PUBLIC_URL}
|
- PUBLIC_IMMICH_API_URL_EXTERNAL=${IMMICH_API_URL_EXTERNAL}
|
||||||
restart: always
|
restart: always
|
||||||
|
|
||||||
redis:
|
redis:
|
||||||
|
|||||||
@@ -54,7 +54,7 @@ services:
|
|||||||
environment:
|
environment:
|
||||||
# Rename these values for svelte public interface
|
# Rename these values for svelte public interface
|
||||||
- PUBLIC_IMMICH_SERVER_URL=${IMMICH_SERVER_URL}
|
- PUBLIC_IMMICH_SERVER_URL=${IMMICH_SERVER_URL}
|
||||||
- PUBLIC_IMMICH_SERVER_PUBLIC_URL=${IMMICH_SERVER_PUBLIC_URL}
|
- PUBLIC_IMMICH_API_URL_EXTERNAL=${IMMICH_API_URL_EXTERNAL}
|
||||||
restart: always
|
restart: always
|
||||||
|
|
||||||
redis:
|
redis:
|
||||||
|
|||||||
+1
-1
@@ -62,7 +62,7 @@ class ImmichApi {
|
|||||||
|
|
||||||
// Browser side (public) API client
|
// Browser side (public) API client
|
||||||
export const api = new ImmichApi();
|
export const api = new ImmichApi();
|
||||||
api.setBaseUrl(env.PUBLIC_IMMICH_SERVER_PUBLIC_URL || '/api');
|
api.setBaseUrl(env.PUBLIC_IMMICH_API_URL_EXTERNAL || '/api');
|
||||||
|
|
||||||
// Server side API client
|
// Server side API client
|
||||||
export const serverApi = new ImmichApi();
|
export const serverApi = new ImmichApi();
|
||||||
|
|||||||
Reference in New Issue
Block a user