Skip to content

Commit 21fa469

Browse files
davispuhekohl
authored andcommitted
server: support specifying video settings
1 parent 497adc7 commit 21fa469

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

lib/fog/libvirt/models/compute/server.rb

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@ class Server < Fog::Compute::Server
3030
attribute :cpu
3131
attribute :hugepages
3232
attribute :guest_agent
33+
attribute :video
3334
attribute :virtio_rng
3435

3536
attribute :state
@@ -413,7 +414,7 @@ def to_xml
413414
graphics.passwd = display[:password] if display[:password] && !display[:password].empty?
414415

415416
xml.video do
416-
xml.model(:type => "cirrus", :vram => 9216, :heads => 1)
417+
xml.model(video)
417418
end
418419
end
419420
end
@@ -532,6 +533,7 @@ def defaults
532533
:cpu => {},
533534
:hugepages => false,
534535
:guest_agent => true,
536+
:video => {:type => "cirrus", :vram => 9216, :heads => 1},
535537
:virtio_rng => {},
536538
}
537539
end

0 commit comments

Comments
 (0)