Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
slapos
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
Ophélie Gagnard
slapos
Commits
ab285b26
Commit
ab285b26
authored
Apr 28, 2021
by
Xavier Thompson
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
software/slaprunner: Enable hateoas in slapos.cfg
parent
c5172a7f
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
9 additions
and
12 deletions
+9
-12
software/slaprunner/buildout.hash.cfg
software/slaprunner/buildout.hash.cfg
+1
-1
software/slaprunner/template/slapos.cfg.in
software/slaprunner/template/slapos.cfg.in
+1
-0
software/slaprunner/test/test.py
software/slaprunner/test/test.py
+7
-11
No files found.
software/slaprunner/buildout.hash.cfg
View file @
ab285b26
...
...
@@ -50,7 +50,7 @@ md5sum = 7a2f5e25a818cb29964666ada7852a5c
[template-slapos-cfg]
filename = template/slapos.cfg.in
md5sum =
3b228b26a170f3c07c50a0f2ae056daf
md5sum =
03322b8a0f42ea579d35981211359190
[template-slapformat-definition.cfg]
filename = template/slapformat-definition.cfg.in
...
...
software/slaprunner/template/slapos.cfg.in
View file @
ab285b26
...
...
@@ -13,6 +13,7 @@ shared_part_list =
{%- endfor %}
{{ slaprunner['shared_root'] }}
master_url = http://{{ slaprunner['ipv4'] }}:{{ slaprunner['proxy_port'] }}
master_rest_url = http://{{ slaprunner['ipv4'] }}:{{ slaprunner['proxy_port'] }}/hateoas
computer_id = slaprunner
maximal_delay = 0
root_check = {{ slaprunner['root_check'] }}
...
...
software/slaprunner/test/test.py
View file @
ab285b26
...
...
@@ -53,10 +53,6 @@ setUpModule, SlapOSInstanceTestCase = makeModuleSetUpAndTestCaseClass(
os
.
path
.
join
(
os
.
path
.
dirname
(
__file__
),
'..'
,
'software%s.cfg'
%
(
"-py3"
if
six
.
PY3
else
""
))))
class
SlaprunnerTestCase
(
SlapOSInstanceTestCase
):
# Slaprunner uses unix sockets, so it needs short paths.
__partition_reference__
=
's'
class
SlaprunnerTestCase
(
SlapOSInstanceTestCase
):
# Slaprunner uses unix sockets, so it needs short paths.
__partition_reference__
=
's'
...
...
@@ -423,14 +419,14 @@ class TestSlapOS(SlaprunnerTestCase):
def
test_slapos_command
(
self
):
# in ~/bin/slapos there is a wrapper setting configuration to use slapos from
# the web runner.
proxy_show_output
=
subprocess
.
check_output
(
(
os
.
path
.
join
(
self
.
computer_partition_root_path
,
'bin'
,
'slapos'
),
'proxy'
,
'show'
,
),
env
=
{})
slapos
=
os
.
path
.
join
(
self
.
computer_partition_root_path
,
'bin'
,
'slapos'
)
# ensure the node is formatted
subprocess
.
check_call
((
slapos
,
'node'
,
'format'
,
'--now'
),
env
=
{})
proxy_show_output
=
subprocess
.
check_output
((
slapos
,
'proxy'
,
'show'
),
env
=
{})
self
.
assertIn
(
b'slaprunner'
,
proxy_show_output
)
# check hateoas cli support
computer_list_output
=
subprocess
.
check_output
((
slapos
,
'computer'
,
'list'
),
env
=
{})
self
.
assertIn
(
b'slaprunner'
,
computer_list_output
)
def
test_shared_part_list
(
self
):
# this slapos used shared_part_list
...
...
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