Upon creation, a VDC template is not accessible to any organization in the system. To enable organizations to create VDCs from a template, a system administrator must use the VMware Cloud Director API access control mechanism to grant those organizations ReadOnly access to the template, and must also grant organization members rights to view and instantiate VDC templates.
A system administrator can make a request similar to the ones described in
Controlling Access to vApps and Catalogs to control access to VDC templates.
Important: The rights to view and instantiate VDC templates are restricted to the system administrator by default. The system administrator must explicitly grant those rights to organization members or roles to enable use of VDC templates in an organization.
Prerequisites
This operation is restricted to system administrators.
Procedure
Results
Example: Grant Access to a VDC Template
This request grants access to a VDC template to two organizations.
Request:
POST https://vcloud.example.com/api/admin/extension/vdcTemplate/100/action/controlAccess Content-Type: application/vnd.vmware.vcloud.controlAccess+xml ... <ControlAccessParams xmlns:vmext="http://www.vmware.com/vcloud/extension/v1.5" xmlns="http://www.vmware.com/vcloud/v1.5"> <IsSharedToEveryone>false</IsSharedToEveryone> <AccessSettings> <AccessSetting> <Subject href="https://vcloud.example.com/api/org/5"></Subject> <AccessLevel>ReadOnly</AccessLevel> </AccessSetting> <AccessSetting> <Subject href="https://vcloud.example.com/api/org/26"></Subject> <AccessLevel>ReadOnly</AccessLevel> </AccessSetting> </AccessSettings> </ControlAccessParams>
The response is a ControlAccessParams element.
Response:
200 OK Content-Type: application/vnd.vmware.vcloud.controlAccess+xml ... <ControlAccessParams xmlns:vmext="http://www.vmware.com/vcloud/extension/v1.5" xmlns="http://www.vmware.com/vcloud/v1.5" \> ... </ControlAccessParams>