Description of problem: Version-Release number of selected component (if applicable): 5.6.0.8 How reproducible: 100% Steps to Reproduce: using the automate explorer: 1) Copy the /System/CommonMethods/QuotaMethods/quota_source method to a writable enabled domain. quota_source method. # # Description: Get quota source. # @miq_request = $evm.root['miq_request'] $evm.root['quota_source_type'] = $evm.parent['quota_source_type'] || $evm.object['quota_source_type'] if $evm.root['quota_source_type'].casecmp('group').zero? $evm.root['quota_source'] = @miq_request.requester.current_group else $evm.root['quota_source'] = @miq_request.tenant $evm.root['quota_source_type'] = 'user' end 2) Edit the copied quota_source method: a.set the quota_source_type to group. 3) Validate and save method. 4) Copy the /System/CommonMethods/QuotaStateMachine/Quota instance to a writable enabled domain. 5) Modify the copied Quota instance to set desired quota test values. for ex: set the quota for cpu only or you can also set it by tagging. 6) Run test(Provision service and/or VMs). Actual results: Quota enforcement for user as quota source does not work Expected results: Quota enforcement for user as quota source should work Additional info:
https://github.com/ManageIQ/manageiq/pull/9198
New commit detected on ManageIQ/manageiq/master: https://github.com/ManageIQ/manageiq/commit/b086426c1b1dbf0cf6cc0fa3db574bf6b7ac4cae commit b086426c1b1dbf0cf6cc0fa3db574bf6b7ac4cae Author: william fitzgerald <wfitzger> AuthorDate: Tue Jun 14 11:48:54 2016 -0400 Commit: william fitzgerald <wfitzger> CommitDate: Tue Jun 14 15:37:18 2016 -0400 Automate - Quota enforcement for user fix Modified Log message to display quota source. Added new spec test for user quota. https://bugzilla.redhat.com/show_bug.cgi?id=1342180 Modified log message to include 'source'. .../System/CommonMethods/QuotaMethods.class/__methods__/limits.rb | 2 +- .../CommonMethods/QuotaMethods.class/__methods__/quota_source.rb | 5 ++++- spec/automation/unit/method_validation/quota_source_spec.rb | 7 +++++++ 3 files changed, 12 insertions(+), 2 deletions(-)
https://github.com/ManageIQ/manageiq/pull/7620
Verified in 5.7.0.3 When copying and modifying /System/CommonMethods/QuotaStateMachine/quota to user the user as the quota source and when the user is tagged, the quotas are in effect.