mirror of
https://github.com/OpenNebula/one.git
synced 2025-03-21 14:50:08 +03:00
Fix image size calculation in quotas
This commit is contained in:
parent
ce182b20e4
commit
8e49edff32
@ -82,7 +82,7 @@ class Quota
|
||||
if template['TYPE'] == 'DATABLOCK'
|
||||
template['SIZE'].to_i
|
||||
elsif template['PATH']
|
||||
File.size(template['PATH'])
|
||||
(File.size(template['PATH']).to_f / 2**20).round(2)
|
||||
elsif template['SAVED_VM_ID']
|
||||
vm_id = template['SAVED_VM_ID'].to_i
|
||||
disk_id = template['SAVED_DISK_ID'].to_i
|
||||
|
Loading…
x
Reference in New Issue
Block a user