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
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
Xiaowu Zhang
slapos.package
Commits
f9264415
Commit
f9264415
authored
Jul 19, 2013
by
Jondy Zhao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
slapos-node: add loop until slapos webrunner is installed
parent
3a7bd752
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
16 deletions
+13
-16
windows/scripts/slapos-include.sh
windows/scripts/slapos-include.sh
+13
-16
No files found.
windows/scripts/slapos-include.sh
View file @
f9264415
...
@@ -413,12 +413,13 @@ function create_slapos_webrunner_instance()
...
@@ -413,12 +413,13 @@ function create_slapos_webrunner_instance()
sed
-e
"s/^.*, CN=//g"
|
sed
-e
"s%/emailAddress.*
\$
%%g"
)
sed
-e
"s/^.*, CN=//g"
|
sed
-e
"s%/emailAddress.*
\$
%%g"
)
[[
"
${
_guid
}
"
==
COMP-+
([
0-9]
)
]]
||
[[
"
${
_guid
}
"
==
COMP-+
([
0-9]
)
]]
||
csih_error
"Invalid computer id '
${
_guid
}
' specified."
csih_error
"Invalid computer id '
${
_guid
}
' specified."
echo
Got computer guid:
${
_guid
}
_title
=
"SlapOS-Node-Runner-In-
${
_guid
}
"
_title
=
"SlapOS-Node-Runner-In-
${
_guid
}
"
if
[[
-r
$re6stnet_configure_file
]]
;
then
if
[[
-r
$re6stnet_configure_file
]]
;
then
_re6stnet_ipv6
=
$(
grep
"Your subnet"
$re6stnet_configure_file
|
\
_re6stnet_ipv6
=
$(
grep
"Your subnet"
$re6stnet_configure_file
|
\
sed
-e
"s/^.*subnet: //g"
-e
"s/
\/
80 (CN.*
\$
/1/g"
)
sed
-e
"s/^.*subnet: //g"
-e
"s/
\/
80 (CN.*
\$
/1/g"
)
if
[[
!
-z
"
${
_re6stnet_ipv6
}
"
]]
;
then
if
[[
-n
"
${
_re6stnet_ipv6
}
"
]]
;
then
echo
"Re6stnet address in this computer:
${
_re6stnet_ipv6
}
"
echo
"Re6stnet address in this computer:
${
_re6stnet_ipv6
}
"
netsh interface ipv6 show addr
$slapos_ifname
level
=
normal |
\
netsh interface ipv6 show addr
$slapos_ifname
level
=
normal |
\
grep
-q
${
_re6stnet_ipv6
}
||
\
grep
-q
${
_re6stnet_ipv6
}
||
\
...
@@ -446,10 +447,7 @@ function create_slapos_webrunner_instance()
...
@@ -446,10 +447,7 @@ function create_slapos_webrunner_instance()
fi
fi
/opt/slapos/bin/slapos node instance
--verbose
/opt/slapos/bin/slapos node instance
--verbose
/opt/slapos/bin/slapos node report
--verbose
/opt/slapos/bin/slapos node report
--verbose
/opt/slapos/bin/slapos request
$client_config_file
${
_title
}
\
slaposwebrunner
--node
computer_guid
=
${
_guid
}
&&
break
sleep
3
done
# Connection parameters of instance are:
# Connection parameters of instance are:
# {'backend_url': 'http://[2001:67c:1254:45::c5d5]:50000',
# {'backend_url': 'http://[2001:67c:1254:45::c5d5]:50000',
# 'cloud9-url': 'http://localhost:9999',
# 'cloud9-url': 'http://localhost:9999',
...
@@ -459,9 +457,8 @@ function create_slapos_webrunner_instance()
...
@@ -459,9 +457,8 @@ function create_slapos_webrunner_instance()
_url
=
$(
/opt/slapos/bin/slapos request
$client_config_file
\
_url
=
$(
/opt/slapos/bin/slapos request
$client_config_file
\
${
_title
}
slaposwebrunner
--node
computer_guid
=
${
_guid
}
|
\
${
_title
}
slaposwebrunner
--node
computer_guid
=
${
_guid
}
|
\
grep
backend_url |
sed
-e
"s/^.*': '//g"
-e
"s/',.*
$/
/g"
)
grep
backend_url |
sed
-e
"s/^.*': '//g"
-e
"s/',.*
$/
/g"
)
echo
"SlapOS Web Runner URL:
${
_url
}
"
[[
-n
"
${
_url
}
"
]]
&&
echo
"SlapOS Web Runner URL:
${
_url
}
"
&&
break
[[
-z
"
${
_url
}
"
]]
&&
\
done
csih_error
"Failed to create instance of SlapOS Web Runner."
cat
<<
EOF
>
$slaprunner_startup_file
cat
<<
EOF
>
$slaprunner_startup_file
<html>
<html>
...
...
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