mirror of
https://github.com/OpenNebula/one.git
synced 2025-03-22 18:50:08 +03:00
* F #3293 Read driver action on attach_disk using STDIN for vcenter drivers * Update attach_disk
This commit is contained in:
parent
776d5629dd
commit
8440eac802
@ -30,13 +30,13 @@ $LOAD_PATH << File.dirname(__FILE__)
|
||||
require 'vcenter_driver'
|
||||
|
||||
vm_ref = ARGV[0]
|
||||
drv_action_enc = ARGV[4]
|
||||
|
||||
drv_action = OpenNebula::XMLElement.new
|
||||
drv_action.initialize_xml(Base64.decode64(drv_action_enc),
|
||||
'VMM_DRIVER_ACTION_DATA')
|
||||
|
||||
host_id = drv_action['VM/HISTORY_RECORDS/HISTORY/HID']
|
||||
# Read from STDIN instead of ARGV[4] to avoid broken pipe error
|
||||
drv_action.initialize_xml(Base64.decode64(STDIN.read), 'VMM_DRIVER_ACTION_DATA')
|
||||
|
||||
host_id = drv_action['/VMM_DRIVER_ACTION_DATA/VM/HISTORY_RECORDS/HISTORY/HID']
|
||||
|
||||
vc_cluster_name = drv_action['/VMM_DRIVER_ACTION_DATA/HOST']
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user