lib/fog/compute/google/models/disk.rb in fog-google-1.9.1 vs lib/fog/compute/google/models/disk.rb in fog-google-1.10.0
- old
+ new
@@ -15,10 +15,13 @@
attribute :source_image, :aliases => "sourceImage"
attribute :source_image_id, :aliases => "sourceImageId"
attribute :source_snapshot, :aliases => "sourceSnapshot"
attribute :source_snapshot_id, :aliases => "sourceSnapshotId"
attribute :type
+ attribute :labels
+ attribute :label_fingerprint, :aliases => "labelFingerprint"
+ attribute :users
def default_description
if !source_image.nil?
"created from image: #{source_image}"
elsif !source_snapshot.nil?
@@ -34,11 +37,12 @@
options = {
:description => description || default_description,
:type => type,
:size_gb => size_gb,
:source_image => source_image,
- :source_snapshot => source_snapshot
- }
+ :source_snapshot => source_snapshot,
+ :labels => labels
+ }.reject { |_, v| v.nil? }
if options[:source_image]
unless source_image.include?("projects/")
options[:source_image] = service.images.get(source_image).self_link
end