Skip to content

Commit

Permalink
fix: container templates to create image in compute resource (#327)
Browse files Browse the repository at this point in the history
fixes #328
  • Loading branch information
Manisha15 authored Jun 18, 2024
1 parent 60f4159 commit 8f86f79
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions app/models/foreman_fog_proxmox/proxmox_images.rb
Original file line number Diff line number Diff line change
Expand Up @@ -48,9 +48,14 @@ def templates
volumes = []
nodes.each do |node|
storages(node.node).each do |storage|
# fetches volumes of QEMU servers for images
volumes += storage.volumes.list_by_content_type('images')

# fetches volumes of KVM containers for images
volumes += storage.volumes.list_by_content_type('rootdir')
end
end
# for creating image, only list volumes which are templated
volumes.select(&:template?)
end

Expand Down

0 comments on commit 8f86f79

Please sign in to comment.