在线观看不卡亚洲电影_亚洲妓女99综合网_91青青青亚洲娱乐在线观看_日韩无码高清综合久久

鍍金池/ 問答/網(wǎng)絡(luò)安全/ node.js http-proxy-middleware 請(qǐng)求代理connec

node.js http-proxy-middleware 請(qǐng)求代理connectrefuse

啟動(dòng)了兩個(gè)node.js服務(wù),A服務(wù)將請(qǐng)求轉(zhuǎn)發(fā)給B,
A代理配置如下
var proxy = require('http-proxy-middleware');
app.use('/api',proxy({

target:'http:192.168.10.111:3000',
secure:false,
changeOrigin: true

}));
結(jié)果轉(zhuǎn)發(fā)是A報(bào)錯(cuò)Error occurred while trying to proxy request /api/2018-06-13 from localhost:4001 to http:192.168.10.111:3000 (ECONNREFUSED)

回答
編輯回答
伴謊

target寫錯(cuò)了。。。搞了半天

2018年4月29日 23:02