angular在配置hosts后访问出现Invalid host header

angular:localhost:4205

hosts: 127.0.0.1 cas.woyujiezhen.com

url输入:cas.woyujiezhen.com:4205

显示invalid host header

解决办法:angular.json 

 

"serve": {
"options": {
"port": 4205,
"disableHostCheck": true
},
}

posted on 2023-03-08 09:11  我欲皆真  阅读(164)  评论(0编辑  收藏  举报

导航