Пример #1
0
 def test_0002(self):
     """List extensions"""
     system = System(session=self.vca.vcloud_session,
                     verify=self.vca.verify,
                     log=self.vca.log)
     extensions = system.get_extensions()
     assert extensions
Пример #2
0
vca = VCA(host=host,
          username=username,
          service_type='standalone',
          version=version,
          verify=verify,
          log=log)

result = vca.login(password=password, org=org, org_url=org_url)
print_vca(vca)

system = System(session=vca.vcloud_session, verify=verify, log=log)
# orgs = system.get_orgs()
# print(json.dumps(orgs))

extensions = system.get_extensions()
print(extensions)

sys.exit(0)

extension_name = 'gcp-ticketing'
extension_metadata = """
<vmext:Service xmlns="http://www.vmware.com/vcloud/v1.5" xmlns:vmext="http://www.vmware.com/vcloud/extension/v1.5" name="%s">
   <vmext:Namespace>%s</vmext:Namespace>
   <vmext:Enabled>true</vmext:Enabled>
   <vmext:RoutingKey>%s</vmext:RoutingKey>
   <vmext:Exchange>vcdext</vmext:Exchange>
   <vmext:ApiFilters>
      <vmext:ApiFilter>
         <vmext:UrlPattern>(/api/org/.*/%s/*[0-9]*)</vmext:UrlPattern>
      </vmext:ApiFilter>