Skip to content
Snippets Groups Projects
Commit b9c65d71 authored by Mohamed, Fawzi Roberto (fawzi)'s avatar Mohamed, Fawzi Roberto (fawzi)
Browse files

new prefix/cM/* for start and commands, use prefix, remove baseUri

analytics-toolkit beaker still using old /notebook-edit entrypoint
parent f4af2f64
No related branches found
No related tags found
No related merge requests found
...@@ -14,12 +14,11 @@ const yaml = require('js-yaml') ...@@ -14,12 +14,11 @@ const yaml = require('js-yaml')
var baseRepl = { var baseRepl = {
baseDir: baseDir, baseDir: baseDir,
baseUri: config.app.baseUri, prefix: config.k8component.image.prefix
baseUriPath: url.parse(config.app.baseUri).path
}; };
// ensure that baseUriPath does not end with / // ensure that prefix does not end with /
if (baseRepl.baseUriPath.endsWith('/')) if (baseRepl.prefix.endsWith('/'))
baseRepl.baseUriPath = baseRepl.baseUriPath.slice(0, baseRepl.baseUriPath.length -1) baseRepl.prefix = baseRepl.prefix.slice(0, baseRepl.prefix.length -1)
const br = config.app.baseReplacements const br = config.app.baseReplacements
for (k in br) for (k in br)
baseRepl[k] = br[k]; baseRepl[k] = br[k];
... ...
......
...@@ -26,4 +26,10 @@ ...@@ -26,4 +26,10 @@
port: 6390, port: 6390,
host: 'analytics-toolkit.nomad-coe.eu' host: 'analytics-toolkit.nomad-coe.eu'
} }
k8component: {
entryPoint: {
path: "/notebook-edit/*"
pathReStr: "/notebook-edit(/[^?#]*)(\\?[^#]*)?(#.*)?$"
}
}
} }
...@@ -12,9 +12,7 @@ k8component: { ...@@ -12,9 +12,7 @@ k8component: {
liveDelay: 15 liveDelay: 15
} }
entryPoint: { entryPoint: {
path: "/notebook-edit/*" redirectTarget: "{{prefix}}/#/open?uri={{escapedPath1}}"
pathReStr: "/notebook-edit(/[^?#]*)(\\?[^#]*)?(#.*)?$"
redirectTarget: "{{baseUri}}/beaker/#/open?uri={{escapedPath1}}"
execCommand: [] execCommand: []
exclusiveStartPoint: false exclusiveStartPoint: false
} }
... ...
......
...@@ -8,7 +8,6 @@ k8component: { ...@@ -8,7 +8,6 @@ k8component: {
image: "analytics-toolkit.nomad-coe.eu:5509/nomadlab/jupyter-image:0.999" image: "analytics-toolkit.nomad-coe.eu:5509/nomadlab/jupyter-image:0.999"
port: 8888, port: 8888,
prefix: "/jupyter", prefix: "/jupyter",
homePath: "/home/beaker"
healthPath: "/jupyter" healthPath: "/jupyter"
healthDelay: 2 healthDelay: 2
healthPeriod: 10 healthPeriod: 10
...@@ -19,7 +18,7 @@ k8component: { ...@@ -19,7 +18,7 @@ k8component: {
"entryPoint": { "entryPoint": {
"path": "/jupyter/entrypoint" "path": "/jupyter/entrypoint"
"uriRe": "/jupyter(/.*)", "uriRe": "/jupyter(/.*)",
"redirectTarget": "{{baseUri}}/jupyter/tree?", "redirectTarget": "{{prefix}}/tree?",
"exclusiveStartPoint": false "exclusiveStartPoint": false
}, },
} }
...@@ -9,7 +9,6 @@ app: { ...@@ -9,7 +9,6 @@ app: {
resolveCacheNMax: 30000 resolveCacheNMax: 30000
pageReloadTime: 5 pageReloadTime: 5
frontendAddr: "http://127.0.0.1:4200" frontendAddr: "http://127.0.0.1:4200"
baseUri: "http://127.0.0.1"
catchErrors: false catchErrors: false
templatesDir: "{{baseDir}}/templates" templatesDir: "{{baseDir}}/templates"
baseReplacements: { baseReplacements: {
...@@ -71,14 +70,14 @@ k8component: { ...@@ -71,14 +70,14 @@ k8component: {
checksumSkipReStr: "^(?:path[0-9]*|escapedPath[0-9]*)$" checksumSkipReStr: "^(?:path[0-9]*|escapedPath[0-9]*)$"
} }
entryPoint: { entryPoint: {
path: "/notebook-edit/*" path: "{{commands}}/start/*"
pathReStr: "/notebook-edit(/[^?#]*)(\\?[^#]*)?(#.*)?$" pathReStr: "/start(/[^?#]*)(\\?[^#]*)?(#.*)?$"
redirectTarget: "{{baseUri}}/beaker/#/open?uri={{escapedPath1}}" redirectTarget: "{{prefix}}/"
execCommand: [] execCommand: []
exclusiveStartPoint: false exclusiveStartPoint: false
} }
commands: { commands: {
path: "{{baseUriPath}}/cM" path: "{{prefix}}/cM"
} }
} }
userInfo: { userInfo: {
... ...
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment