Add release runtime bootstrap implementation with unit and E2E tests
- Create `releaseBootstrap.js` service to handle runtime configuration and remote frontend loading. - Integrate runtime-aware API URL resolution across components and services. - Update i18n phrases to clarify new domains for `ssl_domain_message`. - Enhance unit and E2E tests to validate runtime-based frontend loading and fallback behavior. - Refactor session-related API calls and incorporate runtime-configured base URLs.
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
import axios from "axios";
|
||||
import { enqueueRequest } from "@/services/requestQueue.js";
|
||||
import { rewriteReleaseApiUrl } from "@/services/releaseTimeline.js";
|
||||
|
||||
let requestInterceptorId = null;
|
||||
|
||||
@@ -29,6 +30,13 @@ export const installAxiosRequestQueue = () => {
|
||||
}
|
||||
|
||||
requestInterceptorId = axios.interceptors.request.use((config) => {
|
||||
if (config?.__skipReleaseApiRewrite !== true && config?.url) {
|
||||
config.url = rewriteReleaseApiUrl(config.url);
|
||||
}
|
||||
if (config?.__skipReleaseApiRewrite !== true && config?.baseURL) {
|
||||
config.baseURL = rewriteReleaseApiUrl(config.baseURL);
|
||||
}
|
||||
|
||||
if (isQueueBypassed(config) || config?.__queueAdapterWrapped) {
|
||||
return config;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user