Skip to content

Commit

Permalink
fix: proxy config
Browse files Browse the repository at this point in the history
  • Loading branch information
Xiphoseer committed May 13, 2024
1 parent c0ac3f5 commit 7beb8b8
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 20 deletions.
4 changes: 2 additions & 2 deletions angular.json
Original file line number Diff line number Diff line change
Expand Up @@ -63,14 +63,14 @@
]
}
},
"defaultConfiguration": "production",
"defaultConfiguration": "production"
},
"serve": {
"builder": "@angular-devkit/build-angular:dev-server",
"defaultConfiguration": "",
"options": {
"browserTarget": "lu-explorer:build:development",
"proxyConfig": "src/proxy.conf.json"
"proxyConfig": "src/proxy.conf.js"
},
"configurations": {
"production": {
Expand Down
17 changes: 17 additions & 0 deletions src/proxy.conf.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
const PROXY_CONFIG = [{
context: [
"/lu-docs",
"/lu-json",
"/lu-res",
"/api"
],
logLevel: "debug",
target: "https://explorer.lu",
secure: false,
changeOrigin: true,
bypass: function (req, res, proxyOptions) {
req.headers["Authorization"] = "Basic bHU6ZXhwbG9yZXI=";
}
}];

module.exports = PROXY_CONFIG;
18 changes: 0 additions & 18 deletions src/proxy.conf.json

This file was deleted.

0 comments on commit 7beb8b8

Please sign in to comment.