mirror of
https://github.com/alibaba/anyproxy.git
synced 2025-04-24 06:21:26 +00:00
test config
This commit is contained in:
parent
1f32f77c8c
commit
ef9f00630d
1
bin.js
1
bin.js
@ -26,4 +26,5 @@ if(program.clear){
|
||||
});
|
||||
}else{
|
||||
new proxy.proxyServer(program.type,program.port, program.host ,program.rule);
|
||||
|
||||
}
|
@ -257,16 +257,16 @@ function mergeCORSHeader(reqHeader,originHeader){
|
||||
targetObj["access-control-allow-headers"] = reqHeader['access-control-request-headers'] || "-___-||";
|
||||
|
||||
//
|
||||
targetObj["Transfer-Encoding"] = "chunked";
|
||||
// targetObj["Transfer-Encoding"] = "chunked";
|
||||
|
||||
// Disable caching
|
||||
// If the response status is 304 not modified, the data event of response will not emmit
|
||||
targetObj["Cache-Control"] = "no-cache, no-store, must-revalidate";
|
||||
targetObj["Pragma"] = "no-cache";
|
||||
targetObj["Expires"] = 0;
|
||||
//
|
||||
targetObj["server"] = "anyproxy server";
|
||||
targetObj["x-powered-by"] = "Alipay-ct-wd";
|
||||
// // Disable caching
|
||||
// // If the response status is 304 not modified, the data event of response will not emmit
|
||||
// targetObj["Cache-Control"] = "no-cache, no-store, must-revalidate";
|
||||
// targetObj["Pragma"] = "no-cache";
|
||||
// targetObj["Expires"] = 0;
|
||||
// //
|
||||
// targetObj["server"] = "anyproxy server";
|
||||
// targetObj["x-powered-by"] = "Alipay-ct-wd";
|
||||
|
||||
return targetObj;
|
||||
}
|
||||
|
@ -33,7 +33,7 @@ var rules = {
|
||||
]
|
||||
,"httpsConfig":{
|
||||
"bypassAll" : false, //by setting this to true, anyproxy will not intercept any https request
|
||||
"interceptDomains":[/www\.a\.com/,/www\.b\.com/] //by setting bypassAll:false, requests towards these domains will be intercepted, and try to meet the map rules above
|
||||
"interceptDomains":[/www\.alipay\.com/,/www\.b\.com/] //by setting bypassAll:false, requests towards these domains will be intercepted, and try to meet the map rules above
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user