Skip to content

feat(deploy): configure backend URL at runtime - #93

Merged
DIvanCode merged 2 commits into
masterfrom
codex/runtime-backend-url
Aug 10, 2026
Merged

feat(deploy): configure backend URL at runtime#93
DIvanCode merged 2 commits into
masterfrom
codex/runtime-backend-url

Conversation

@DIvanCode

Copy link
Copy Markdown
Owner

Summary

  • build the Frontend image with a runtime-replaceable backend URL marker
  • inject VITE_BASE_URL into the generated JavaScript when the container starts
  • move VITE_BASE_URL from the image build playbook to the deployment container environment

Why

Vite previously embedded VITE_BASE_URL while building the image, so changing the backend required rebuilding the Frontend image. The same image can now be started with different backend URLs.

Verification

Not run by explicit request: local tests, build, and production-bundle browser smoke test were waived for this publication.

What to test manually

Prerequisite: a reachable backend and, for authenticated checks, a test account.

  1. Deploy the image with VITE_BASE_URL set to the backend API URL.
  2. Open the application and confirm the authentication screen loads and API requests use that URL.
  3. Sign in and open a duel-capable screen; confirm HTTP requests and the user WebSocket connect through the configured backend.
  4. Restart the same image with another backend URL and confirm the application switches targets without rebuilding the image.
  5. As regressions, verify direct-route reloads still fall back to index.html and static assets are served normally.

Closes #92

@DIvanCode
DIvanCode marked this pull request as ready for review August 10, 2026 06:00

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: c689809bfb

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread docker-entrypoint.d/inject-backend-url.sh
@DIvanCode
DIvanCode merged commit 60990c9 into master Aug 10, 2026
7 checks passed
@DIvanCode
DIvanCode deleted the codex/runtime-backend-url branch August 10, 2026 06:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[box][Frontend] Возможность указания url бэкенда при запуске контейнера

1 participant