-
Notifications
You must be signed in to change notification settings - Fork 3
/
vue.config.js
34 lines (33 loc) ยท 987 Bytes
/
vue.config.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
const { defineConfig } = require('@vue/cli-service')
const path = require('path')
module.exports = defineConfig({
transpileDependencies: true,
chainWebpack: (config) => {
// eslint ๋ฃฐ์ ์ญ์ ํ์ฌ ESLint๋ฅผ ๋นํ์ฑํํฉ๋๋ค.
config.module.rules.delete('eslint')
},
configureWebpack: {
resolve: {
alias: {
'@': path.resolve(__dirname, 'src')
}
}
},
devServer: {
proxy: {
'/api': {
target:
'http://ec2-43-202-20-87.ap-northeast-2.compute.amazonaws.com:8080', // ์ค์ ์๋ฒ ์ฃผ์
changeOrigin: true,
secure: false, // HTTPS๊ฐ ์๋ ๊ฒฝ์ฐ false๋ก ์ค์
pathRewrite: { '^/api': '/api' }, // ํ๋ก์ ๊ฒฝ๋ก ์ ์ง
onProxyReq: (proxyReq) => {
// ํ๋ก์ ์์ฒญ์ ์ฟ ํค ์ค์
proxyReq.setHeader('Cookie', 'SameSite=None; Secure')
},
withCredentials: true // ์ฟ ํค๋ฅผ ํฌํจํ์ฌ ์ ์ก
}
},
port: 3000
}
})