Unverified Commit 38ca4c99 authored by Andinus's avatar Andinus Committed by GitHub
Browse files

Refresh after spinoff (#1601)

fix(backend): Refresh after spinoff

From UPC#1567

    When a clone is spinned off, the XML contents of the source file are outdated.

After spinoff we refresh volume info, that should update XML definition.
parent 7c4dcacf
......@@ -2625,6 +2625,7 @@ sub _post_remove_base {
sub _post_spinoff($self) {
my $sth = $$CONNECTOR->dbh->prepare("UPDATE domains set id_base=NULL WHERE id=?");
$sth->execute($self->id);
$self->list_volumes_info();
}
sub _pre_shutdown_domain {}
......@@ -3341,7 +3342,7 @@ sub _open_exposed_port($self, $internal_port, $name, $restricted) {
if !$internal_ip || $internal_ip !~ /^(\d+\.\d+)/;
if ($public_port
&& ( $self->_used_ports_iptables($public_port, "$internal_ip:$internal_port")
&& ( $self->_used_ports_iptables($public_port, "$internal_ip:$internal_port")
|| $self->_used_port_displays($public_port,$id_port))
) {
warn $self->name." cleared duplicate $public_port\n"
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment