Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
SlapOS Develop
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
Eric Zheng
SlapOS Develop
Commits
16e38173
Commit
16e38173
authored
Sep 07, 2011
by
Cédric de Saint Martin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add numpy in NoVNC path. Solves bug 20110819-11F4F70
parent
977179b9
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
12 deletions
+13
-12
slapos/recipe/kvm/__init__.py
slapos/recipe/kvm/__init__.py
+13
-8
stack/kvm.cfg
stack/kvm.cfg
+0
-4
No files found.
slapos/recipe/kvm/__init__.py
View file @
16e38173
...
@@ -61,8 +61,7 @@ class Recipe(BaseSlapRecipe):
...
@@ -61,8 +61,7 @@ class Recipe(BaseSlapRecipe):
noVNC_conf
=
self
.
installNoVnc
(
source_ip
=
self
.
getGlobalIPv6Address
(),
noVNC_conf
=
self
.
installNoVnc
(
source_ip
=
self
.
getGlobalIPv6Address
(),
source_port
=
6080
,
source_port
=
6080
,
target_ip
=
kvm_conf
[
'vnc_ip'
],
target_ip
=
kvm_conf
[
'vnc_ip'
],
target_port
=
vnc_port
,
target_port
=
vnc_port
)
python_path
=
kvm_conf
[
'python_path'
])
self
.
linkBinary
()
self
.
linkBinary
()
self
.
computer_partition
.
setConnectionDict
(
dict
(
self
.
computer_partition
.
setConnectionDict
(
dict
(
...
@@ -167,8 +166,7 @@ class Recipe(BaseSlapRecipe):
...
@@ -167,8 +166,7 @@ class Recipe(BaseSlapRecipe):
return
kvm_conf
return
kvm_conf
def
installNoVnc
(
self
,
source_ip
,
source_port
,
target_ip
,
target_port
,
def
installNoVnc
(
self
,
source_ip
,
source_port
,
target_ip
,
target_port
):
python_path
):
"""
"""
Create noVNC configuration dictionnary and instanciate Websockify proxy
Create noVNC configuration dictionnary and instanciate Websockify proxy
...
@@ -181,14 +179,20 @@ class Recipe(BaseSlapRecipe):
...
@@ -181,14 +179,20 @@ class Recipe(BaseSlapRecipe):
noVNC_conf
=
{}
noVNC_conf
=
{}
noVNC_conf
[
'source_ip'
]
=
source_ip
noVNC_conf
[
'source_ip'
]
=
source_ip
noVNC_conf
[
'source_port'
]
=
source_port
noVNC_conf
[
'source_port'
]
=
source_port
# Install numpy.
# XXX-Cedric : this looks like a hack. Do we have better solution, knowing
# That websockify is not an egg?
numpy
=
zc
.
buildout
.
easy_install
.
install
([
'numpy'
],
self
.
options
[
'eggs-directory'
])
environment
=
dict
(
PYTHONPATH
=
'%s'
%
numpy
.
entries
[
0
])
# Instanciate Websockify
# Instanciate Websockify
websockify_runner_path
=
zc
.
buildout
.
easy_install
.
scripts
([(
'websockify'
,
websockify_runner_path
=
zc
.
buildout
.
easy_install
.
scripts
([(
'websockify'
,
'slapos.recipe.librecipe.execute'
,
'execute_wait'
)],
self
.
ws
,
'slapos.recipe.librecipe.execute'
,
'execute
e
_wait'
)],
self
.
ws
,
sys
.
executable
,
self
.
wrapper_directory
,
arguments
=
[
sys
.
executable
,
self
.
wrapper_directory
,
arguments
=
[
[
python_path
.
strip
(),
[
sys
.
executable
.
strip
(),
self
.
options
[
'websockify_path'
],
self
.
options
[
'websockify_path'
],
'--web'
,
'--web'
,
self
.
options
[
'noVNC_location'
],
self
.
options
[
'noVNC_location'
],
...
@@ -197,7 +201,8 @@ class Recipe(BaseSlapRecipe):
...
@@ -197,7 +201,8 @@ class Recipe(BaseSlapRecipe):
'--ssl-only'
,
'--ssl-only'
,
'%s:%s'
%
(
source_ip
,
source_port
),
'%s:%s'
%
(
source_ip
,
source_port
),
'%s:%s'
%
(
target_ip
,
target_port
)],
'%s:%s'
%
(
target_ip
,
target_port
)],
[
self
.
certificate_path
,
self
.
key_path
]]
[
self
.
certificate_path
,
self
.
key_path
],
environment
]
)[
0
]
)[
0
]
self
.
path_list
.
append
(
websockify_runner_path
)
self
.
path_list
.
append
(
websockify_runner_path
)
...
...
stack/kvm.cfg
View file @
16e38173
...
@@ -25,10 +25,6 @@ extends =
...
@@ -25,10 +25,6 @@ extends =
# Websockify (socket <-> websocket proxy server) when it is ready.
# Websockify (socket <-> websocket proxy server) when it is ready.
# May solve previous XXX depending on the implementation.
# May solve previous XXX depending on the implementation.
#XXX-Cedric: Check status of
# https://www.tiolive.com/nexedi/bug_module/20110819-11F4F70 for
# Chrome >= 14 and Firefox >=7 can access to noVNC.
parts =
parts =
template
template
gnutls
gnutls
...
...
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