You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by "luganofer (via GitHub)" <gi...@apache.org> on 2025/05/16 23:51:59 UTC

[I] Add global setting to enable/disable service offering creation for end users (optionally zone-scoped) [cloudstack]

luganofer opened a new issue, #10886:
URL: https://github.com/apache/cloudstack/issues/10886

   ### The required feature described as a wish
   
   ### Description
   
   This proposal introduces an enhancement to the CloudStack UI and API to allow administrators to enable or disable the ability for end users to create new compute and disk offerings, through a Global Setting.
   
   In environments where strict governance or pre-approved resource configurations are required, it is useful to prevent users from creating custom service offerings, while still allowing administrators to manage and offer pre-defined options.
   
   ### Feature Summary
   
   * Introduce one or more Global Settings to control:
    ** Whether end users can create compute (service) offerings
    ** Whether end users can create disk offerings
   * Optional enhancement: allow this control to be zone-specific via scoped settings or dynamic checks.
   
   
   ### Use Case
   
   CloudStack installations used in multi-tenant environments, or those operated by service providers, often need to limit the customization of offerings to admins only, to ensure compliance with internal policies, cost control, and performance baselines.
   
   This feature would allow:
   
   * Disabling offering creation for end users in production zones while enabling it in sandbox/test zones
   * Preventing accidental or non-compliant offering creation in shared environments
   * Improving UX by hiding or disabling the relevant UI options when not permitted
   
   ### Proposed Changes
   1) Introduce two new global settings:
   * allow.user.create.service.offering (default: true)
   * allow.user.create.disk.offering (default: true)
   2) (Optional) Extend setting to support zone-specific override
   3) Modify UI and API behavior to check these settings:
   * Hide or disable relevant buttons/forms if disabled
   * Reject API requests with an appropriate error if blocked


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@cloudstack.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [I] Add global setting to enable/disable service offering creation for end users (optionally zone-scoped) [cloudstack]

Posted by "DaanHoogland (via GitHub)" <gi...@apache.org>.
DaanHoogland commented on issue #10886:
URL: https://github.com/apache/cloudstack/issues/10886#issuecomment-2933973622

   > Hi [@DaanHoogland](https://github.com/DaanHoogland) , thanks for the feedback.
   
   np
   
   > If you have hundreds of accounts and thousands of users that belong to an account with the role ‘Domain Admin’ (role that is assigned to an end customer by default in most cases) you have to think about a migration process of creating not only the roles that deny those APIs (that wouldn't be much effort) , you also have to recreate the hundreds of accounts with the new role and also recreate the thousands of users in these new accounts to inherit this new role and force the thousands of users to re-register the 2FA if this feature is active. Unless you do something nasty to the database, of course.
   
   Why do you think the recreation of accounts is needed? A account can be assigned a new role, and this can be scripted with APIs. These are the ones you would need:
   https://cloudstack.apache.org/api/apidocs-4.20/apis/createRole.html
   https://cloudstack.apache.org/api/apidocs-4.20/apis/updateRolePermission.html
   https://cloudstack.apache.org/api/apidocs-4.20/apis/updateAccount.html
   only the last one would be called on all those users. The users/accounts will continue to exist with all their data.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [I] Add global setting to enable/disable service offering creation for end users (optionally zone-scoped) [cloudstack]

Posted by "luganofer (via GitHub)" <gi...@apache.org>.
luganofer commented on issue #10886:
URL: https://github.com/apache/cloudstack/issues/10886#issuecomment-2916856290

   > [@luganofer](https://github.com/luganofer) , is rule based roles an option for you? you can disable the APIs for creation and updating of offerings per role.
   
   Hi @DaanHoogland...I understand that it should be possible by removing the roles you indicate.  In large CloudStack deployments (with hundreds or thousands of accounts) it is quite complex to modify those roles.  The functionality that I'm pointing out, in addition to introducing/removing the possibility that the customer can or cannot create service offers, would also allow to discriminate this by zones in turn.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [I] Add global setting to enable/disable service offering creation for end users (optionally zone-scoped) [cloudstack]

Posted by "luganofer (via GitHub)" <gi...@apache.org>.
luganofer commented on issue #10886:
URL: https://github.com/apache/cloudstack/issues/10886#issuecomment-2931147371

   > I don’t understand how a lot of accounts would matter, [@luganofer](https://github.com/luganofer). There has to be only one role that needs to be denied that API. All and users can be assigned that same role. in a little worse case it will be three roles that need to be created, but certainly not much worse..
   
   Hi Dan, thanks for the feedback.
   If you have hundreds of accounts and thousands of users that belong to an account with the role ‘Domain Admin’ (role that is assigned to an end customer by default  in most cases) you have to think about a migration process of creating not only the roles that deny those APIs (that wouldn't be much effort) , you also have to recreate the hundreds of accounts with the new role and also recreate the thousands of users in these new accounts to inherit this new role and force the thousands of users to re-register the 2FA if this feature is active. Unless you do something nasty to the database, of course.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [I] Add global setting to enable/disable service offering creation for end users (optionally zone-scoped) [cloudstack]

Posted by "DaanHoogland (via GitHub)" <gi...@apache.org>.
DaanHoogland commented on issue #10886:
URL: https://github.com/apache/cloudstack/issues/10886#issuecomment-2916212336

   @luganofer , is rule based roles an option for you? you can disable the APIs for creation and updating of offerings per role.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [I] Add global setting to enable/disable service offering creation for end users (optionally zone-scoped) [cloudstack]

Posted by "luganofer (via GitHub)" <gi...@apache.org>.
luganofer closed issue #10886: Add global setting to enable/disable service offering creation for end users (optionally zone-scoped)
URL: https://github.com/apache/cloudstack/issues/10886


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [I] Add global setting to enable/disable service offering creation for end users (optionally zone-scoped) [cloudstack]

Posted by "luganofer (via GitHub)" <gi...@apache.org>.
luganofer commented on issue #10886:
URL: https://github.com/apache/cloudstack/issues/10886#issuecomment-2950667207

   > > Hi [@DaanHoogland](https://github.com/DaanHoogland) , thanks for the feedback.
   > 
   > np
   > 
   > > If you have hundreds of accounts and thousands of users that belong to an account with the role ‘Domain Admin’ (role that is assigned to an end customer by default in most cases) you have to think about a migration process of creating not only the roles that deny those APIs (that wouldn't be much effort) , you also have to recreate the hundreds of accounts with the new role and also recreate the thousands of users in these new accounts to inherit this new role and force the thousands of users to re-register the 2FA if this feature is active. Unless you do something nasty to the database, of course.
   > 
   > Why do you think the recreation of accounts is needed? A account can be assigned a new role, and this can be scripted with APIs. These are the ones you would need: https://cloudstack.apache.org/api/apidocs-4.20/apis/createRole.html https://cloudstack.apache.org/api/apidocs-4.20/apis/updateRolePermission.html https://cloudstack.apache.org/api/apidocs-4.20/apis/updateAccount.html only the last one would be called on all those users. The users/accounts will continue to exist with all their data.
   
   You are right 🥇  @DaanHoogland .  From the APIs it is possible to assign a new role to the accounts and I wasn't aware of that ( thank you for the tip!).  The good thing about this is we can make the changes we need without waiting for the new functionality 😄  


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [I] Add global setting to enable/disable service offering creation for end users (optionally zone-scoped) [cloudstack]

Posted by "DaanHoogland (via GitHub)" <gi...@apache.org>.
DaanHoogland commented on issue #10886:
URL: https://github.com/apache/cloudstack/issues/10886#issuecomment-2925107383

   I don’t understand how a lot of accounts would matter, @luganofer. There has to be only one role that needs to be denied that API. All and users can be assigned that same role. in a little worse case it will be three roles that need to be created, but certainly not much worse..


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org