ccj 3 lat temu
rodzic
commit
94fafaeae7
3 zmienionych plików z 5 dodań i 3 usunięć
  1. 1 1
      package.json
  2. 1 1
      public/index.html
  3. 3 1
      vue.config.js

+ 1 - 1
package.json

@@ -4,7 +4,7 @@
   "description": "A vue admin template with Element UI & axios & iconfont & permission control & lint",
   "author": "Pan <panfree23@gmail.com>",
   "scripts": {
-    "dev": "vue-cli-service serve",
+    "dev": "vue-cli-service serve --host 0.0.0.0",
     "build:prod": "vue-cli-service build",
     "build:stage": "vue-cli-service build --mode staging",
     "preview": "node build/index.js --preview",

+ 1 - 1
public/index.html

@@ -5,7 +5,7 @@
     <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
     <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
     
-  <meta http-equiv="Content-Security-Policy" content="upgrade-insecure-requests">
+  <meta http-equiv="Content-Security-Policy" >
     <link rel="icon" href="<%= BASE_URL %>favicon.ico">
     <title><%= webpackConfig.name %></title>
   </head>

+ 3 - 1
vue.config.js

@@ -46,6 +46,8 @@ module.exports = {
   lintOnSave: process.env.NODE_ENV === 'development',
   productionSourceMap: false,
   devServer: {
+    https:false,
+    host:'0.0.0.0',
     port: port,
     disableHostCheck: true,
     open: false,
@@ -55,7 +57,7 @@ module.exports = {
     },
     proxy: {
       '/pb': {
-        target: 'http://192.168.110.9:8099/',
+        target: 'http://192.168.110.67:8090/',
         // target: 'https://apitest.eliangeyun.com',
         changeOrigin: true, // 开启代理:在本地会创建一个虚拟服务端,然后发送请求的数据,并同时接收请求的数据,这样服务端和服务端进行数据的交互就不会有跨域问题
         pathRewrite: { '^/pb': '/' }, // 这里重写路径