[PR #577] [MERGED] Use runtime env var for login page message to lower web container startup time #8674

Closed
opened 2026-02-05 13:51:21 +03:00 by OVERLORD · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/immich-app/immich/pull/577
Author: @bo0tzz
Created: 9/4/2022
Status: Merged
Merged: 9/5/2022
Merged by: @alextran1502

Base: mainHead: dev/web-env-var


📝 Commits (4)

  • 332e9e8 Use runtime env var for loginPageMessage
  • 1b5b3a6 Rename VITE_LOGIN_PAGE_MESSAGE to PUBLIC_LOGIN_PAGE_MESSAGE in .env.example
  • 1e11a9b Move docker image npm run build step into Dockerfile
  • 6bf837b Remove comment from web Dockerfile

📊 Changes

4 files changed (+6 additions, -7 deletions)

View changed files

📝 docker/.env.example (+2 -2)
📝 web/Dockerfile (+2 -3)
📝 web/entrypoint.sh (+0 -1)
📝 web/src/lib/constants.ts (+2 -1)

📄 Description

With the new sveltekit version, we can use runtime environment variables. This PR changes the VITE_LOGIN_PAGE_MESSAGE to use those runtime env vars, allowing us to run the vite build when building the Docker image rather than at startup time.

This does require renaming the env var to PUBLIC_LOGIN_PAGE_MESSAGE.

The runtime env var change works, but the change to the docker build is currently resulting in a runtime error. It would be nice to get a second pair of eyes on that.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/immich-app/immich/pull/577 **Author:** [@bo0tzz](https://github.com/bo0tzz) **Created:** 9/4/2022 **Status:** ✅ Merged **Merged:** 9/5/2022 **Merged by:** [@alextran1502](https://github.com/alextran1502) **Base:** `main` ← **Head:** `dev/web-env-var` --- ### 📝 Commits (4) - [`332e9e8`](https://github.com/immich-app/immich/commit/332e9e8b9dd846b12622e66911263630da3506ee) Use runtime env var for loginPageMessage - [`1b5b3a6`](https://github.com/immich-app/immich/commit/1b5b3a6455e6569d1477e6dc53116bd2a6d37b5d) Rename VITE_LOGIN_PAGE_MESSAGE to PUBLIC_LOGIN_PAGE_MESSAGE in .env.example - [`1e11a9b`](https://github.com/immich-app/immich/commit/1e11a9b6aaf6e215970a1ad4503f37a9e82a08eb) Move docker image `npm run build` step into Dockerfile - [`6bf837b`](https://github.com/immich-app/immich/commit/6bf837b9f87d4729dba1f1d5594b27cfa9d174bb) Remove comment from web Dockerfile ### 📊 Changes **4 files changed** (+6 additions, -7 deletions) <details> <summary>View changed files</summary> 📝 `docker/.env.example` (+2 -2) 📝 `web/Dockerfile` (+2 -3) 📝 `web/entrypoint.sh` (+0 -1) 📝 `web/src/lib/constants.ts` (+2 -1) </details> ### 📄 Description With the new sveltekit version, we can use [runtime environment variables](https://kit.svelte.dev/docs/modules#$env-dynamic-private). This PR changes the VITE_LOGIN_PAGE_MESSAGE to use those runtime env vars, allowing us to run the vite build when building the Docker image rather than at startup time. This does require renaming the env var to PUBLIC_LOGIN_PAGE_MESSAGE. ~~The runtime env var change works, but the change to the docker build is currently resulting in a runtime error. It would be nice to get a second pair of eyes on that.~~ --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
OVERLORD added the pull-request label 2026-02-05 13:51:21 +03:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: immich-app/immich#8674