mirror of
https://github.com/apotdevin/thunderhub.git
synced 2025-02-22 06:21:37 +01:00
test: change api handler url
This commit is contained in:
parent
3ebbde43c9
commit
21d6b185aa
2 changed files with 3 additions and 2 deletions
|
@ -14,6 +14,7 @@ module.exports = withBundleAnalyzer({
|
|||
publicRuntimeConfig: {
|
||||
nodeEnv: process.env.NODE_ENV || 'development',
|
||||
apiUrl: `${process.env.BASE_PATH || ''}/api/v1`,
|
||||
apiBaseUrl: `${process.env.API_BASE_URL || ''}/api/v1`,
|
||||
basePath: process.env.BASE_PATH || '',
|
||||
npmVersion: process.env.npm_package_version || '0.0.0',
|
||||
},
|
||||
|
|
|
@ -5,7 +5,7 @@ import getConfig from 'next/config';
|
|||
import Cors from 'micro-cors';
|
||||
|
||||
const { publicRuntimeConfig } = getConfig();
|
||||
const { apiUrl } = publicRuntimeConfig;
|
||||
const { apiBaseUrl } = publicRuntimeConfig;
|
||||
|
||||
const cors = Cors({
|
||||
origin: true,
|
||||
|
@ -19,7 +19,7 @@ const apolloServer = new ApolloServer({
|
|||
},
|
||||
});
|
||||
|
||||
const handler = apolloServer.createHandler({ path: apiUrl });
|
||||
const handler = apolloServer.createHandler({ path: apiBaseUrl });
|
||||
|
||||
export const config = {
|
||||
api: {
|
||||
|
|
Loading…
Add table
Reference in a new issue