Actions
Bug #6100
closedUnable to delete interfaces and volumes from compute profiles
Status:
Duplicate
Priority:
Normal
Assignee:
-
Category:
Compute resources
Target version:
-
Description
Create a compute profile with two interfaces or volumes, then edit it, click the crosses and save. When you view the profile again, they'll still be there. Tested on libvirt + VMware.
The deleted entries aren't actually being removed from the hash before save. Instead, they're getting saved to the DB with _delete=1!
(0.4ms) UPDATE "compute_attributes" SET "vm_attrs" = '--- !ruby/hash:ActiveSupport::HashWithIndifferentAccess cpus: ''1'' memory: ''805306368'' nics_attributes: !ruby/hash:ActiveSupport::HashWithIndifferentAccess new_nics: !ruby/hash:ActiveSupport::HashWithIndifferentAccess type: bridge _delete: '''' bridge: em1 model: virtio ''0'': !ruby/hash:ActiveSupport::HashWithIndifferentAccess type: bridge _delete: '''' bridge: em1 model: virtio ''1'': !ruby/hash:ActiveSupport::HashWithIndifferentAccess type: network _delete: ''1'' network: hundred model: virtio volumes_attributes: !ruby/hash:ActiveSupport::HashWithIndifferentAccess new_volumes: !ruby/hash:ActiveSupport::HashWithIndifferentAccess pool_name: default capacity: 10G allocation: 0G format_type: raw _delete: '''' ''0'': !ruby/hash:ActiveSupport::HashWithIndifferentAccess pool_name: default capacity: 10G allocation: 0G format_type: raw _delete: '''' ''1'': !ruby/hash:ActiveSupport::HashWithIndifferentAccess pool_name: default capacity: 10G allocation: 0G format_type: raw _delete: ''1'' image_id: /home/libvirt/foreman_template.img ', "updated_at" = '2014-06-06 17:49:46.519459' WHERE "compute_attributes"."id" = 4
Actions