Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
slapos.toolbox
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Klaus Wölfel
slapos.toolbox
Commits
7e119508
Commit
7e119508
authored
Dec 09, 2013
by
Nicolas Wavrant
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
slaprunner: /myAccount can render user-defined paramters
parent
82d02800
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
2 deletions
+12
-2
slapos/runner/utils.py
slapos/runner/utils.py
+8
-0
slapos/runner/views.py
slapos/runner/views.py
+4
-2
No files found.
slapos/runner/utils.py
View file @
7e119508
...
@@ -41,6 +41,14 @@ html_escape_table = {
...
@@ -41,6 +41,14 @@ html_escape_table = {
"<"
:
"<"
,
"<"
:
"<"
,
}
}
def
getBuildAndRunParams
():
dict_params
=
{
'run_instance'
:
RUN_INSTANCE
,
'run_software'
:
RUN_SOFTWARE
,
'max_run_instance'
:
MAX_RUN_INSTANCE
,
'max_run_software'
:
MAX_RUN_SOFTWARE
}
return
dict_params
def
html_escape
(
text
):
def
html_escape
(
text
):
"""Produce entities within text."""
"""Produce entities within text."""
...
...
slapos/runner/views.py
View file @
7e119508
...
@@ -14,7 +14,8 @@ from flask import (Flask, request, redirect, url_for, render_template,
...
@@ -14,7 +14,8 @@ from flask import (Flask, request, redirect, url_for, render_template,
from
slapos.runner.process
import
killRunningProcess
from
slapos.runner.process
import
killRunningProcess
from
slapos.runner.utils
import
(
checkSoftwareFolder
,
configNewSR
,
getProfilePath
,
from
slapos.runner.utils
import
(
checkSoftwareFolder
,
configNewSR
,
getProfilePath
,
listFolder
,
getProjectTitle
,
getSession
,
listFolder
,
getBuildAndRunParams
,
getProjectTitle
,
getSession
,
getSlapStatus
,
getSvcStatus
,
getSlapStatus
,
getSvcStatus
,
getSvcTailProcess
,
isInstanceRunning
,
getSvcTailProcess
,
isInstanceRunning
,
isSoftwareRunning
,
isSoftwareReleaseReady
,
isText
,
isSoftwareRunning
,
isSoftwareReleaseReady
,
isText
,
...
@@ -85,7 +86,8 @@ def setAccount():
...
@@ -85,7 +86,8 @@ def setAccount():
def
myAccount
():
def
myAccount
():
account
=
getSession
(
app
.
config
)
account
=
getSession
(
app
.
config
)
return
render_template
(
'account.html'
,
username
=
account
[
0
],
return
render_template
(
'account.html'
,
username
=
account
[
0
],
email
=
account
[
2
],
name
=
account
[
3
].
decode
(
'utf-8'
))
email
=
account
[
2
],
name
=
account
[
3
].
decode
(
'utf-8'
),
params
=
getBuildAndRunParams
())
@
app
.
route
(
"/dologout"
)
@
app
.
route
(
"/dologout"
)
...
...
Write
Preview
Markdown
is supported
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