generate spice devices cmd line after pci bridge

we should push to $devices array instead $cmd array,

because pci bridges need to be create before spice devices

Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
This commit is contained in:
Alexandre Derumier 2014-08-13 01:04:31 +02:00 committed by Dietmar Maurer
parent f73de1699c
commit d2da6d9b8e

View File

@ -2694,11 +2694,11 @@ sub config_to_command {
$spice_port = PVE::Tools::next_spice_port();
push @$cmd, '-spice', "tls-port=${spice_port},addr=127.0.0.1,tls-ciphers=DES-CBC3-SHA,seamless-migration=on";
push @$devices, '-spice', "tls-port=${spice_port},addr=127.0.0.1,tls-ciphers=DES-CBC3-SHA,seamless-migration=on";
push @$cmd, '-device', "virtio-serial,id=spice$pciaddr";
push @$cmd, '-chardev', "spicevmc,id=vdagent,name=vdagent";
push @$cmd, '-device', "virtserialport,chardev=vdagent,name=com.redhat.spice.0";
push @$devices, '-device', "virtio-serial,id=spice$pciaddr";
push @$devices, '-chardev', "spicevmc,id=vdagent,name=vdagent";
push @$devices, '-device', "virtserialport,chardev=vdagent,name=com.redhat.spice.0";
}
# enable balloon by default, unless explicitly disabled