Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
slapos.package.keep
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
Ivan Tyagov
slapos.package.keep
Commits
afeb78aa
Commit
afeb78aa
authored
Apr 15, 2013
by
Cédric de Saint Martin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fixup
parent
902e5487
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
18 additions
and
6 deletions
+18
-6
slapprepare/slapprepare/slapprepare.py
slapprepare/slapprepare/slapprepare.py
+18
-6
No files found.
slapprepare/slapprepare/slapprepare.py
View file @
afeb78aa
...
...
@@ -455,9 +455,9 @@ class Config:
if
not
get_yes_no
(
"A SlapOS Node configuration has been found. Do you want to overwrite it?"
,
False
):
print
"Okay, let's start from scratch."
return
False
self
.
master_url
=
raw_input
(
"""SlapOS Master URL? Empty answer will make it use slapos.org :"""
)
self
.
master_url
=
raw_input
(
"""SlapOS Master URL? Empty answer will make it use slapos.org
Master
:"""
)
if
self
.
master_url
:
self
.
master_url_web
=
raw_input
(
"""SlapOS Master "web" URL?
Default is "https://www.slapos.org"
:"""
)
self
.
master_url_web
=
raw_input
(
"""SlapOS Master "web" URL?:"""
)
else
:
self
.
master_url_web
=
''
self
.
computer_name
=
raw_input
(
"Define a unique name for this computer: "
)
...
...
@@ -489,8 +489,12 @@ class Config:
def
displayUserConfig
(
self
):
# XXX print everything from configuration, not arbitrary members
if
self
.
certificates
:
print
"Will register a computer on master"
if
self
.
master_url
:
print
"URL of master: %s"
%
self
.
master_url
print
"URL
\
"
web
\
"
of master: %s"
%
self
.
master_url_web
print
"Number of partition: %s"
%
(
self
.
partition_amount
)
print
"Computer name: %s"
%
self
.
computer_name
print
"Virtual Machine: %s"
%
self
.
virtual
...
...
@@ -527,10 +531,18 @@ def prepare_from_scratch(config):
# Prepare Slapos Configuration
if
config
.
certificates
:
_call
([
'slapos'
,
'node'
,
'register'
,
config
.
computer_name
,
'--interface-name'
,
'br0'
,
'--ipv6-interface'
,
config
.
ipv6_interface
,
'--partition-number'
,
config
.
partition_amount
])
slapos_register_parameter_list
=
[
'slapos'
,
'node'
,
'register'
,
config
.
computer_name
,
'--interface-name'
,
'br0'
,
'--ipv6-interface'
,
config
.
ipv6_interface
,
'--partition-number'
,
config
.
partition_amount
]
if
config
.
master_url
:
slapos_register_parameter_list
.
extend
([
'--master-url'
,
config
.
master_url
,
'--master-url-web'
,
config
.
master_url_web
,
])
_call
(
slapos_register_parameter_list
)
if
getSlaposConfiguration
():
if
config
.
need_bridge
:
...
...
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