diff options
Diffstat (limited to 'packages/client/vue.config.js')
-rw-r--r-- | packages/client/vue.config.js | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/packages/client/vue.config.js b/packages/client/vue.config.js new file mode 100644 index 0000000..94cfb20 --- /dev/null +++ b/packages/client/vue.config.js @@ -0,0 +1,25 @@ +const yaml = require("js-yaml"); +const fs = require("fs"); + +const settings = yaml.load(fs.readFileSync(`${__dirname}/../../settings.yml`, "utf8")); + +module.exports = { + devServer: { + host: settings.host, + port: settings.dev_port, + proxy: { + "^/api": { + target: `http://${settings.host}:${settings.port}`, + changeOrigin: true + }, + "^/[a-zA-Z0-9\\.\\-_]+/info/refs": { + target: `http://${settings.host}:${settings.port}`, + changeOrigin: true + }, + "^/[a-zA-Z0-9\\.\\-_]+/git-upload-pack": { + target: `http://${settings.host}:${settings.port}`, + changeOrigin: true + } + } + } +}; |