Skip to content

Commit

Permalink
Merge branch 'release-1.0.0' of github.com:tekdi/teachers-app into re…
Browse files Browse the repository at this point in the history
…lease-1.0.0
  • Loading branch information
itsvick committed Nov 11, 2024
2 parents 76c1869 + a56ef39 commit 3f4d529
Showing 1 changed file with 10 additions and 6 deletions.
16 changes: 10 additions & 6 deletions next.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,15 @@ const remotes = (isServer) => {
};
};

const PORTAL_BASE_URL = "https://sunbird-editor.tekdinext.com";
const PORTAL_BASE_URL = 'https://sunbird-editor.tekdinext.com';

const routes = {
API: {
GENERAL: {
CONTENT_PREVIEW: "/content/preview/:path*",
CONTENT_PLUGINS: "/content-plugins/:path*"
}
}
CONTENT_PREVIEW: '/content/preview/:path*',
CONTENT_PLUGINS: '/content-plugins/:path*',
},
},
};

const nextConfig = {
Expand Down Expand Up @@ -52,6 +52,10 @@ const nextConfig = {
source: '/play/content/assets/:path*', // Match any URL starting with /workspace/content/assets/
destination: `${process.env.WORKSPACE_BASE_URL}/assets/:path*`, // Serve the assets from the public folder
},
{
source: '/action/v1/telemetry',
destination: `${process.env.NEXT_PUBLIC_TELEMETRY_URL}/v1/telemetry`,
},
{
source: '/action/asset/:path*', // Match other /action/asset routes
destination: `${process.env.WORKSPACE_BASE_URL}/api/proxy?path=/action/asset/:path*`, // Forward other /action/asset requests to proxy.js
Expand Down Expand Up @@ -84,7 +88,7 @@ const nextConfig = {
{
source: routes.API.GENERAL.CONTENT_PLUGINS,
destination: `${PORTAL_BASE_URL}${routes.API.GENERAL.CONTENT_PLUGINS}`, // Proxy to portal
}
},
];
},
webpack: (config, { isServer }) => {
Expand Down

0 comments on commit 3f4d529

Please sign in to comment.