@abtnode/router-provider 1.16.40-beta-20250311-152346-f596c9a6 → 1.16.40-beta-20250313-033531-8d70107e
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/nginx/index.js +6 -1
- package/lib/util.js +1 -0
- package/package.json +6 -6
package/lib/nginx/index.js
CHANGED
|
@@ -503,6 +503,7 @@ class NginxProvider extends BaseProvider {
|
|
|
503
503
|
targetPrefix, // used to strip prefix from target
|
|
504
504
|
ruleId,
|
|
505
505
|
type,
|
|
506
|
+
proxyBehavior,
|
|
506
507
|
commonHeaders,
|
|
507
508
|
cacheGroup,
|
|
508
509
|
pageGroup,
|
|
@@ -563,7 +564,11 @@ class NginxProvider extends BaseProvider {
|
|
|
563
564
|
|
|
564
565
|
// Rewrite path
|
|
565
566
|
location._add('rewrite', `^${rewritePathPrefix}/?(.*) /$1 break`);
|
|
566
|
-
|
|
567
|
+
if (proxyBehavior === 'direct') {
|
|
568
|
+
location._add('proxy_pass', `http://127.0.0.1:${port}`);
|
|
569
|
+
} else {
|
|
570
|
+
location._add('proxy_pass', `http://${getUpstreamName(process.env.ABT_NODE_SERVICE_PORT)}`);
|
|
571
|
+
}
|
|
567
572
|
|
|
568
573
|
return;
|
|
569
574
|
}
|
package/lib/util.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@abtnode/router-provider",
|
|
3
|
-
"version": "1.16.40-beta-
|
|
3
|
+
"version": "1.16.40-beta-20250313-033531-8d70107e",
|
|
4
4
|
"description": "Routing engine implementations for abt node",
|
|
5
5
|
"author": "polunzh <polunzh@gmail.com>",
|
|
6
6
|
"homepage": "https://github.com/ArcBlock/blocklet-server#readme",
|
|
@@ -32,10 +32,10 @@
|
|
|
32
32
|
"url": "https://github.com/ArcBlock/blocklet-server/issues"
|
|
33
33
|
},
|
|
34
34
|
"dependencies": {
|
|
35
|
-
"@abtnode/constant": "1.16.40-beta-
|
|
36
|
-
"@abtnode/logger": "1.16.40-beta-
|
|
37
|
-
"@abtnode/router-templates": "1.16.40-beta-
|
|
38
|
-
"@abtnode/util": "1.16.40-beta-
|
|
35
|
+
"@abtnode/constant": "1.16.40-beta-20250313-033531-8d70107e",
|
|
36
|
+
"@abtnode/logger": "1.16.40-beta-20250313-033531-8d70107e",
|
|
37
|
+
"@abtnode/router-templates": "1.16.40-beta-20250313-033531-8d70107e",
|
|
38
|
+
"@abtnode/util": "1.16.40-beta-20250313-033531-8d70107e",
|
|
39
39
|
"@arcblock/http-proxy": "^1.19.1",
|
|
40
40
|
"@arcblock/is-valid-domain": "^1.0.5",
|
|
41
41
|
"axios": "^1.7.9",
|
|
@@ -60,5 +60,5 @@
|
|
|
60
60
|
"bluebird": "^3.7.2",
|
|
61
61
|
"fs-extra": "^11.2.0"
|
|
62
62
|
},
|
|
63
|
-
"gitHead": "
|
|
63
|
+
"gitHead": "34bdd932f825070562a2124557d7198f4a3a9b91"
|
|
64
64
|
}
|