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
Guillaume Hervier
slapos.toolbox
Commits
7495ab2d
Commit
7495ab2d
authored
11 years ago
by
Cédric Le Ninivin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
slaprunner: grammar
parent
dfb607f4
master
apache_mpm_watchdog
cygwin-resdemo
erp5-resiliency-test-no-debug
file_limit
fix-opml
fix-resiliency-test
kvmresiliency
monitor
0.76
0.75
0.74
0.72
0.71
0.70
0.69
0.68
0.67
0.66
0.65
0.64
0.63
0.62
0.61
0.60
0.59
0.58
0.57
0.56
0.55
0.54
0.53
0.52
0.51
0.50
0.49
0.48
0.47.2
0.47.1
0.47
0.46.1
0.46.0
0.45.3
0.45.2
0.45.0
0.44.0
0.43.0
0.42.0
0.41.0
0.40.4
0.40.3
0.40.2
0.40.1
0.40
0.39.4
0.39.3
0.39.2
0.39.1
0.39
0.38.1
0.38
0.37.4
0.37.3
0.37.2
0.37.1
0.37
0.36
0.35.1
0.35
No related merge requests found
Changes
8
Show whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
12 additions
and
12 deletions
+12
-12
slapos/runner/runnertest.py
slapos/runner/runnertest.py
+1
-1
slapos/runner/static/js/scripts/account.js
slapos/runner/static/js/scripts/account.js
+1
-1
slapos/runner/static/js/scripts/folder.js
slapos/runner/static/js/scripts/folder.js
+2
-2
slapos/runner/templates/account.html
slapos/runner/templates/account.html
+2
-2
slapos/runner/templates/cloneRepository.html
slapos/runner/templates/cloneRepository.html
+1
-1
slapos/runner/templates/index.html
slapos/runner/templates/index.html
+1
-1
slapos/runner/utils.py
slapos/runner/utils.py
+3
-3
slapos/runner/views.py
slapos/runner/views.py
+1
-1
No files found.
slapos/runner/runnertest.py
View file @
7495ab2d
...
...
@@ -214,7 +214,7 @@ class SlaprunnerTestCase(unittest.TestCase):
"""Test Login user before create session. This should return error value"""
response
=
self
.
login
(
self
.
users
[
0
],
self
.
users
[
1
])
#redirect to config account page
assert
"<h2 class='title'>Your personal information
s
</h2><br/>"
in
response
.
data
assert
"<h2 class='title'>Your personal information</h2><br/>"
in
response
.
data
def
test_configAccount
(
self
):
"""For the first lauch of slaprunner user need do create first account"""
...
...
This diff is collapsed.
Click to expand it.
slapos/runner/static/js/scripts/account.js
View file @
7495ab2d
...
...
@@ -21,7 +21,7 @@ $(document).ready(function () {
return
false
;
}
if
(
!
$
(
"
input#email
"
).
val
().
match
(
/^
([
a-zA-Z0-9_
\.\-])
+
\@(([
a-zA-Z0-9
\-])
+
\.)
+
([
a-zA-Z0-9
]{2,4})
+$/
))
{
$
(
"
#error
"
).
Popup
(
"
Please enter a valid email adress!
"
,
{
type
:
'
alert
'
,
duration
:
3000
});
$
(
"
#error
"
).
Popup
(
"
Please enter a valid email ad
d
ress!
"
,
{
type
:
'
alert
'
,
duration
:
3000
});
return
false
;
}
if
(
!
hasAccount
&&
!
$
(
"
input#password
"
).
val
())
{
...
...
This diff is collapsed.
Click to expand it.
slapos/runner/static/js/scripts/folder.js
View file @
7495ab2d
...
...
@@ -64,9 +64,9 @@ $(document).ready(function () {
if
(
$
(
"
input#user
"
).
val
()
!==
""
)
{
name
=
$
(
"
input#user
"
).
val
();
}
if
(
$
(
"
input#email
"
).
val
()
!==
''
&&
$
(
"
input#email
"
).
val
()
!==
"
Enter your email adress...
"
)
{
if
(
$
(
"
input#email
"
).
val
()
!==
''
&&
$
(
"
input#email
"
).
val
()
!==
"
Enter your email ad
d
ress...
"
)
{
if
(
!
$
(
"
input#email
"
).
val
().
match
(
/^
([
a-zA-Z0-9_
\.\-])
+
\@(([
a-zA-Z0-9
\-])
+
\.)
+
([
a-zA-Z0-9
]{2,4})
+$/
))
{
$
(
"
#error
"
).
Popup
(
"
Please enter a valid email adress!
"
,
{
type
:
'
alert
'
,
duration
:
3000
});
$
(
"
#error
"
).
Popup
(
"
Please enter a valid email ad
d
ress!
"
,
{
type
:
'
alert
'
,
duration
:
3000
});
return
false
;
}
email
=
$
(
"
input#email
"
).
val
();
...
...
This diff is collapsed.
Click to expand it.
slapos/runner/templates/account.html
View file @
7495ab2d
...
...
@@ -5,13 +5,13 @@
<script
src=
"{{ url_for('static', filename='js/scripts/account.js') }}"
type=
"text/javascript"
charset=
"utf-8"
></script>
{% endblock %}
{% block body %}
<h2
class=
'title'
>
Your personal information
s
</h2><br/>
<h2
class=
'title'
>
Your personal information
</h2><br/>
<form
class=
"account"
>
<div
class=
'form'
>
<label
for=
"name"
>
Your name:
</label>
<input
type=
'text'
name=
'name'
id=
'name'
value=
'{{name}}'
/>
<div
class=
'clear'
></div>
<label
for=
"email"
>
Your email adress:
</label>
<label
for=
"email"
>
Your email ad
d
ress:
</label>
<input
type=
'text'
name=
'email'
id=
'email'
value=
'{{email}}'
/>
<div
class=
'clear'
></div>
<label
for=
"username"
>
User name:
</label>
...
...
This diff is collapsed.
Click to expand it.
slapos/runner/templates/cloneRepository.html
View file @
7495ab2d
...
...
@@ -28,7 +28,7 @@
<label
for=
'user'
>
Your name:
</label>
<input
type=
"text"
name=
"user"
id=
"user"
size=
'20'
value=
"{{name}}"
/>
<label
for=
'email'
>
Email:
</label>
<input
type=
"text"
name=
"email"
id=
"email"
size=
'25'
value=
"{% if not email %}Enter your email adress...{% else %}{{email}}{%endif%}"
/>
<input
type=
"text"
name=
"email"
id=
"email"
size=
'25'
value=
"{% if not email %}Enter your email ad
d
ress...{% else %}{{email}}{%endif%}"
/>
<input
type=
"hidden"
name=
"workdir"
id=
"workdir"
value=
"{{workDir}}"
/>
<button
class=
"button"
id=
"clone"
>
clone
</button>
<img
class=
"waitting"
id=
"imgwaitting"
src=
"{{ url_for('static', filename='images/waiting.gif') }}"
alt=
""
/>
...
...
This diff is collapsed.
Click to expand it.
slapos/runner/templates/index.html
View file @
7495ab2d
...
...
@@ -25,7 +25,7 @@
<div
class=
"clear"
></div>
<div
class=
"umenu"
>
<h2><a
href=
"{{ url_for('myAccount')}}"
>
Your Account
</a></h2>
<p>
Update your account information
s
</p>
<p>
Update your account information
</p>
<img
src=
"{{ url_for('static', filename='images/user_card.png') }}"
/>
</div>
<div
class=
"lmenu smaller"
>
...
...
This diff is collapsed.
Click to expand it.
slapos/runner/utils.py
View file @
7495ab2d
...
...
@@ -41,7 +41,7 @@ def getSession(config):
"""
Get the session data of current user.
Returns:
a list of user information
s
or False if fail to read data.
a list of user information or False if fail to read data.
"""
user_path
=
os
.
path
.
join
(
config
[
'etc_dir'
],
'.users'
)
user
=
""
...
...
@@ -343,7 +343,7 @@ def getProfilePath(projectDir, profile):
return
os
.
path
.
join
(
projectFolder
,
profile
)
def
getSlapStatus
(
config
):
"""Return all Slapos Partitions with associate information
s
"""
"""Return all Slapos Partitions with associate information"""
slap
=
slapos
.
slap
.
slap
()
slap
.
initializeConnection
(
config
[
'master_url'
])
partition_list
=
[]
...
...
@@ -379,7 +379,7 @@ def removeInstanceRoot(config):
shutil
.
rmtree
(
config
[
'instance_root'
])
def
getSvcStatus
(
config
):
"""Return all Softwares Instances process Information
s
"""
"""Return all Softwares Instances process Information"""
result
=
Popen
([
config
[
'supervisor'
],
config
[
'configuration_file_path'
],
'status'
]).
communicate
()[
0
]
regex
=
"(^unix:.+
\
.socke
t
)|(^error:)|(^watchdog).*$"
...
...
This diff is collapsed.
Click to expand it.
slapos/runner/views.py
View file @
7495ab2d
...
...
@@ -428,7 +428,7 @@ def getmd5sum():
else
:
return
jsonify
(
code
=
0
,
result
=
"Can not get md5sum for this file!"
)
#return information
s
about state of slapgrid process
#return information about state of slapgrid process
@
login_required
()
def
slapgridResult
():
software_state
=
isSoftwareRunning
(
app
.
config
)
...
...
This diff is collapsed.
Click to expand it.
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