Skip to content
Snippets Groups Projects
Commit f3d8ba17 authored by Florent Poittevin's avatar Florent Poittevin
Browse files

fix: disable computed auth endpoint for dev env with local backend

parent f6350ddf
No related branches found
No related tags found
No related merge requests found
......@@ -1599,7 +1599,6 @@
"@angular/compiler": "^8.1.3",
"boxen": "^4.1.0",
"colorette": "^1.1.0",
"flat": "git://github.com/lenchvolodymyr/flat.git#ffe77efe8c33bc80ffb2f7a465537610dea4f611",
"gettext-parser": "^4.0.1",
"glob": "^7.1.4",
"mkdirp": "^0.5.1",
......@@ -1650,12 +1649,24 @@
"locate-path": "^3.0.0"
}
},
"flat": {
"version": "git://github.com/lenchvolodymyr/flat.git#ffe77efe8c33bc80ffb2f7a465537610dea4f611",
"from": "git://github.com/lenchvolodymyr/flat.git#ffe77efe8c33bc80ffb2f7a465537610dea4f611",
"requires": {
"is-buffer": "~2.0.3"
}
},
"get-caller-file": {
"version": "2.0.5",
"resolved": "https://nexus.unige.ch/repository/npm-all/get-caller-file/-/get-caller-file-2.0.5.tgz",
"integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==",
"dev": true
},
"is-buffer": {
"version": "2.0.4",
"resolved": "https://nexus.unige.ch/repository/npm-all/is-buffer/-/is-buffer-2.0.4.tgz",
"integrity": "sha512-Kq1rokWXOPXWuaMAqZiJW4XxsmD9zGx9q4aePabbn3qCRGedtH7Cm+zV8WETitMfu1wdh+Rvd6w5egwSngUX2A=="
},
"locate-path": {
"version": "3.0.0",
"resolved": "https://nexus.unige.ch/repository/npm-all/locate-path/-/locate-path-3.0.0.tgz",
......@@ -5827,22 +5838,6 @@
}
}
},
"flat": {
"version": "git://github.com/lenchvolodymyr/flat.git#ffe77efe8c33bc80ffb2f7a465537610dea4f611",
"from": "git://github.com/lenchvolodymyr/flat.git#ffe77ef",
"dev": true,
"requires": {
"is-buffer": "~2.0.3"
},
"dependencies": {
"is-buffer": {
"version": "2.0.4",
"resolved": "https://nexus.unige.ch/repository/npm-all/is-buffer/-/is-buffer-2.0.4.tgz",
"integrity": "sha512-Kq1rokWXOPXWuaMAqZiJW4XxsmD9zGx9q4aePabbn3qCRGedtH7Cm+zV8WETitMfu1wdh+Rvd6w5egwSngUX2A==",
"dev": true
}
}
},
"flatted": {
"version": "2.0.1",
"resolved": "https://nexus.unige.ch/repository/npm-all/flatted/-/flatted-2.0.1.tgz",
......@@ -14306,7 +14301,8 @@
"npm-normalize-package-bin": {
"version": "1.0.1",
"bundled": true,
"dev": true
"dev": true,
"optional": true
},
"npm-packlist": {
"version": "1.4.8",
......@@ -14984,8 +14980,7 @@
"code-point-at": {
"version": "1.1.0",
"bundled": true,
"dev": true,
"optional": true
"dev": true
},
"concat-map": {
"version": "0.0.1",
......@@ -14996,8 +14991,7 @@
"console-control-strings": {
"version": "1.1.0",
"bundled": true,
"dev": true,
"optional": true
"dev": true
},
"core-util-is": {
"version": "1.0.2",
......@@ -15114,8 +15108,7 @@
"inherits": {
"version": "2.0.4",
"bundled": true,
"dev": true,
"optional": true
"dev": true
},
"ini": {
"version": "1.3.5",
......@@ -15127,7 +15120,6 @@
"version": "1.0.0",
"bundled": true,
"dev": true,
"optional": true,
"requires": {
"number-is-nan": "^1.0.0"
}
......@@ -15150,14 +15142,12 @@
"minimist": {
"version": "1.2.5",
"bundled": true,
"dev": true,
"optional": true
"dev": true
},
"minipass": {
"version": "2.9.0",
"bundled": true,
"dev": true,
"optional": true,
"requires": {
"safe-buffer": "^5.1.2",
"yallist": "^3.0.0"
......@@ -15176,7 +15166,6 @@
"version": "0.5.3",
"bundled": true,
"dev": true,
"optional": true,
"requires": {
"minimist": "^1.2.5"
}
......@@ -15238,8 +15227,7 @@
"npm-normalize-package-bin": {
"version": "1.0.1",
"bundled": true,
"dev": true,
"optional": true
"dev": true
},
"npm-packlist": {
"version": "1.4.8",
......@@ -15267,8 +15255,7 @@
"number-is-nan": {
"version": "1.0.1",
"bundled": true,
"dev": true,
"optional": true
"dev": true
},
"object-assign": {
"version": "4.1.1",
......@@ -15280,7 +15267,6 @@
"version": "1.4.0",
"bundled": true,
"dev": true,
"optional": true,
"requires": {
"wrappy": "1"
}
......@@ -15394,7 +15380,6 @@
"version": "1.0.2",
"bundled": true,
"dev": true,
"optional": true,
"requires": {
"code-point-at": "^1.0.0",
"is-fullwidth-code-point": "^1.0.0",
......
module.exports = {
"/api/rss": {
"target": "https://www.unige.ch/feed",
"logLevel": "info",
"secure": "false",
"pathRewrite": {
"^/api": ""
},
"changeOrigin": true
"/api/rss": {
"target": "https://www.unige.ch/feed",
"logLevel": "info",
"secure": "false",
"pathRewrite": {
"^/api": ""
},
"/api/short-doi": {
"target": "http://shortdoi.org",
"pathRewrite": {
"^/api/short-doi": ""
},
"changeOrigin": true,
"changeOrigin": true
},
"/api/short-doi": {
"target": "http://shortdoi.org",
"pathRewrite": {
"^/api/short-doi": ""
},
"/dlcm/authorization/oauth": {
"target": "https://e-research-test.unige.ch/dlcm-test/authorization/oauth",
"pathRewrite": {
"^/dlcm/authorization/oauth": ""
},
"onProxyRes": (proxyRes, req, res) => {
proxyRes.headers['Access-Control-Allow-Origin'] = 'http://localhost:4200';
},
"secure": false,
"changeOrigin": true
}
"changeOrigin": true,
},
}
module.exports = {
"/api/rss": {
"target": "https://www.unige.ch/feed",
"pathRewrite": {
"^/api": ""
},
"changeOrigin": true
"/api/rss": {
"target": "https://www.unige.ch/feed",
"pathRewrite": {
"^/api": ""
},
"/api/short-doi": {
"target": "http://shortdoi.org",
"pathRewrite": {
"^/api/short-doi": ""
},
"changeOrigin": true,
"changeOrigin": true
},
"/api/short-doi": {
"target": "http://shortdoi.org",
"pathRewrite": {
"^/api/short-doi": ""
},
"/dlcm/oauth": {
"target": "http://localhost:16110/dlcm/oauth",
"pathRewrite": {
"^/dlcm/oauth": ""
},
"changeOrigin": true,
},
"/dlcm/oauth": {
"target": "http://localhost:16110/dlcm/oauth",
"pathRewrite": {
"^/dlcm/oauth": ""
},
"/dlcm/shiblogin": {
"target": "http://localhost:16110",
"onProxyReq": (proxyReq, req, res) => {
proxyReq.setHeader('mail', 'Marty.McFly@unige.ch');
proxyReq.setHeader('persistent-id', '999999@unige.ch');
proxyReq.setHeader('uniqueid', '999999@unige.ch');
proxyReq.setHeader('givenname', 'Marty');
proxyReq.setHeader('surname', 'McFly');
proxyReq.setHeader('homeorganization', 'unige.ch');
proxyReq.setHeader('preferredlanguage', 'fr-ch');
},
"onProxyRes": (proxyRes, req, res) => {
proxyRes.headers['Access-Control-Allow-Origin'] = 'http://localhost:4200';
}
},
"/dlcm/shiblogin": {
"target": "http://localhost:16110",
"onProxyReq": (proxyReq, req, res) => {
proxyReq.setHeader('mail', 'Marty.McFly@unige.ch');
proxyReq.setHeader('persistent-id', '999999@unige.ch');
proxyReq.setHeader('uniqueid', '999999@unige.ch');
proxyReq.setHeader('givenname', 'Marty');
proxyReq.setHeader('surname', 'McFly');
proxyReq.setHeader('homeorganization', 'unige.ch');
proxyReq.setHeader('preferredlanguage', 'fr-ch');
},
"onProxyRes": (proxyRes, req, res) => {
proxyRes.headers['Access-Control-Allow-Origin'] = 'http://localhost:4200';
}
},
}
......@@ -25,7 +25,7 @@ export const defaultEnvironment: DlcmEnvironment = {
minimalPageSizeToRetrievePaginationInfo: 1,
maximalPageSizeToRetrievePaginationInfo: 2000,
useSelfHostedStreamSaverMitm: false,
computeOAuthEndpoint: true,
computeOAuthEndpoint: false,
// Base URL For Module Applications (override by AppAction.LoadModules)
admin: "http://localhost:16115/dlcm/admin",
......
......@@ -16,5 +16,6 @@ export const environment: DlcmEnvironment = {
redirectUrl: "http://localhost:4200/",
admin: "https://e-research-test.unige.ch/dlcm-test/administration/admin",
forceRuntimeOverrideSetting: true,
computeOAuthEndpoint: true,
...environmentLocal,
};
......@@ -9,6 +9,7 @@ export const environment: DlcmEnvironment = {
production: true,
theme: ThemeEnum.yareta,
useSelfHostedStreamSaverMitm: true,
computeOAuthEndpoint: true,
admin: "https://test.dlcm.ch/administration/",
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment