From 9dbb09772eef2a8a82ac44f22626eba6911cc81a Mon Sep 17 00:00:00 2001 From: Saturn-V Date: Thu, 8 Feb 2024 15:38:51 -0800 Subject: [PATCH] replace: rewrites with assetPrefix --- next.config.js | 92 +++++++++++++++++++++++++------------------------- 1 file changed, 46 insertions(+), 46 deletions(-) diff --git a/next.config.js b/next.config.js index e6d1a41..ed72b81 100644 --- a/next.config.js +++ b/next.config.js @@ -1,6 +1,6 @@ module.exports = { // basePath: '/k8s/clusters/c-m-6wzgb6p6/api/v1/namespaces/sammwise/services/http:sammwise:80/proxy' || process.env.NEXT_BASE_PATH || '', - // assetPrefix: process.env.NEXT_BASE_PATH || '', + assetPrefix: 'https://rancher.vzxy.net/k8s/clusters/c-m-6wzgb6p6/api/v1/namespaces/sammwise/services/http:sammwise:80/proxy', // assetPrefix: process.env.RANCHER_SERVER || '', // hostname: process.env.RANCHER_SERVER, @@ -14,51 +14,51 @@ module.exports = { // } - async rewrites() { - return [ - { - has: [ - { - type: 'host', - value: 'rancher.vzxy.net', - }, - ], - // source: '/:path*', - source: '/', - destination: '/k8s/clusters/c-m-6wzgb6p6/api/v1/namespaces/sammwise/services/http%3Asammwise%3A80/proxy/', - }, - { - has: [ - { - type: 'host', - value: 'rancher.vzxy.net', - }, - ], - source: '/about', - destination: '/k8s/clusters/c-m-6wzgb6p6/api/v1/namespaces/sammwise/services/http%3Asammwise%3A80/proxy/about', - }, - { - has: [ - { - type: 'host', - value: 'rancher.vzxy.net', - }, - ], - source: '/assessment', - destination: '/k8s/clusters/c-m-6wzgb6p6/api/v1/namespaces/sammwise/services/http%3Asammwise%3A80/proxy/assessment', - }, - { - has: [ - { - type: 'host', - value: 'rancher.vzxy.net', - }, - ], - source: '/results', - destination: '/k8s/clusters/c-m-6wzgb6p6/api/v1/namespaces/sammwise/services/http%3Asammwise%3A80/proxy/results', - }, - ] - } + // async rewrites() { + // return [ + // { + // has: [ + // { + // type: 'host', + // value: 'rancher.vzxy.net', + // }, + // ], + // // source: '/:path*', + // source: '/', + // destination: '/k8s/clusters/c-m-6wzgb6p6/api/v1/namespaces/sammwise/services/http%3Asammwise%3A80/proxy/about', + // }, + // { + // has: [ + // { + // type: 'host', + // value: 'rancher.vzxy.net', + // }, + // ], + // source: '/about', + // destination: '/k8s/clusters/c-m-6wzgb6p6/api/v1/namespaces/sammwise/services/http%3Asammwise%3A80/proxy/about', + // }, + // { + // has: [ + // { + // type: 'host', + // value: 'rancher.vzxy.net', + // }, + // ], + // source: '/assessment', + // destination: '/k8s/clusters/c-m-6wzgb6p6/api/v1/namespaces/sammwise/services/http%3Asammwise%3A80/proxy/assessment', + // }, + // { + // has: [ + // { + // type: 'host', + // value: 'rancher.vzxy.net', + // }, + // ], + // source: '/results', + // destination: '/k8s/clusters/c-m-6wzgb6p6/api/v1/namespaces/sammwise/services/http%3Asammwise%3A80/proxy/results', + // }, + // ] + // } }