Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
nomad-lab
container-manager
Commits
5b27798d
Commit
5b27798d
authored
Sep 26, 2018
by
Mohamed, Fawzi Roberto (fawzi)
Browse files
templates: templates/kube, templates/html
parent
54288fad
Changes
6
Hide whitespace changes
Inline
Side-by-side
app/components.js
View file @
5b27798d
...
...
@@ -32,7 +32,7 @@ baseRepl['commands'] = templatize(cconfig.commands.path)(baseRepl)
// Given a path loads it and compiles a template for it, use loadTemplate that has caching
function
loadTemplateInternal
(
templatePath
,
next
)
{
const
templateRealPath
=
path
.
join
(
templatesDir
,
templatePath
||
"
defaultTemplate.yaml
"
)
const
templateRealPath
=
path
.
join
(
templatesDir
,
templatePath
||
"
kube/
defaultTemplate.yaml
"
)
fs
.
readFile
(
templateRealPath
,
'
utf8
'
,
function
(
err
,
data
)
{
if
(
err
)
{
err
.
message
=
err
.
message
+
` loading
${
templateRealPath
}
`
...
...
@@ -93,7 +93,7 @@ function evalTemplate(templatePath, extraRepl, next) {
}
function
namespaceTemplate
(
name
,
next
)
{
evalTemplate
(
"
namespace.yaml
"
,
{
namespace
:
name
},
next
)
evalTemplate
(
"
kube/
namespace.yaml
"
,
{
namespace
:
name
},
next
)
}
/// returns a short session ID from a long session id
...
...
config/default-remotevis.hjson
View file @
5b27798d
...
...
@@ -6,6 +6,6 @@ k8component: {
port: 8809,
prefix: "/jupyter",
homePath: "/home/beaker"
templatePath: "remoteVisTemplate.yaml"
templatePath: "
kube/
remoteVisTemplate.yaml"
}
}
config/default.hjson
View file @
5b27798d
...
...
@@ -11,7 +11,7 @@ app: {
frontendAddr: "http://127.0.0.1:4200"
baseUri: "http://127.0.0.1"
catchErrors: false
templatesDir: "{{baseDir}}/
kubeT
emplates"
templatesDir: "{{baseDir}}/
t
emplates"
baseReplacements: {
nomadRoot: "/nomad/nomadlab"
}
...
...
@@ -49,7 +49,7 @@ k8component: {
templateCacheNMax: 20
templateCacheTtlMaxMs: 30000
namespace: "analytics"
templatePath: "defaultTemplate.yaml"
templatePath: "
kube/
defaultTemplate.yaml"
keysToProtect: ["keysToProtect", "keysToSkip"]
keysToSkip: ["templateCacheTtlMaxMs", "templateCacheNMax", "keysToSkip", "keysToProtect", "images", "entryPoint", "commands"]
image: {
...
...
kubeT
emplates/defaultTemplate.yaml
→
t
emplates/
kube/
defaultTemplate.yaml
View file @
5b27798d
File moved
kubeT
emplates/namespace.yaml
→
t
emplates/
kube/
namespace.yaml
View file @
5b27798d
File moved
kubeT
emplates/remoteVisTemplate.yaml
→
t
emplates/
kube/
remoteVisTemplate.yaml
View file @
5b27798d
File moved
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment