Skip to content

Commit 6722777

Browse files
author
Bhanu Teja P
committed
Proxy routes
1 parent 0973ea5 commit 6722777

File tree

3 files changed

+13
-1
lines changed

3 files changed

+13
-1
lines changed

.gitignore

+2
Original file line numberDiff line numberDiff line change
@@ -19,3 +19,5 @@ yarn-error.log*
1919
*.njsproj
2020
*.sln
2121
*.sw?
22+
23+
.env

now.json

+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
{
2+
"routes": [
3+
{
4+
"src": "/api/(.*)",
5+
"dest": "https://openrank.herokuapp.com/api/$1"
6+
}
7+
]
8+
}

vue.config.js

+3-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,9 @@ module.exports = {
22
devServer: {
33
proxy: {
44
'/api': {
5-
target: 'http://localhost:8000',
5+
target: 'https://localhost:8000',
6+
ws: true,
7+
changeOrigin: true,
68
headers: {
79
Connection: 'keep-alive',
810
},

0 commit comments

Comments
 (0)