Skip to content

Commit

Permalink
Merge pull request #100 from Ladas/fill_out_guest_os_correctly_euwe
Browse files Browse the repository at this point in the history
[EUWE] Fill guest_os correctly
  • Loading branch information
simaishi authored Jan 13, 2017
2 parents be9f32a + 4430f7f commit 722a022
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -166,8 +166,12 @@ def parse_image(image, is_public)
uid = image.image_id
location = image.image_location
guest_os = (image.platform == "windows") ? "windows" : "linux"
if guest_os == "linux"
guest_os = OperatingSystem.normalize_os_name(location)
guest_os = "linux" if guest_os == "unknown"
end

name = get_from_tags(image, :name)
name = get_from_tags(image, :name)
name ||= image.name
name ||= $1 if location =~ /^(.+?)(\.(image|img))?\.manifest\.xml$/
name ||= uid
Expand Down

0 comments on commit 722a022

Please sign in to comment.