Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Projets publics
Ravada-Mirror
Commits
168c9079
Commit
168c9079
authored
Nov 04, 2019
by
Francesc Guasch
Browse files
wip(backend): search machine in another node if not active
issue #1188
parent
24cd62ef
Changes
1
Show whitespace changes
Inline
Side-by-side
lib/Ravada/Domain.pm
View file @
168c9079
...
...
@@ -1449,6 +1449,8 @@ sub _pre_remove_domain($self, $user, @) {
}
# check the node is active
# search the domain in another node if it is not
sub
_check_active_node
($self) {
return
$self
->
_vm
if
$self
->
_vm
->
is_active
(
1
);
...
...
@@ -1456,7 +1458,9 @@ sub _check_active_node($self) {
next
if
!
$node
->
is_local
;
$self
->
_vm
(
$node
);
$self
->
domain
(
$node
->
search_domain_by_id
(
$self
->
id
)
->
domain
);
my
$domain_active
=
$node
->
search_domain_by_id
(
$self
->
id
);
next
if
!
$domain_active
;
$self
->
domain
(
$domain_active
->
domain
);
last
;
}
return
$self
->
_vm
;
...
...
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