Documentation ¶
Index ¶
- type Account
- type AddressWithType
- type Appliance
- type ApplianceEndpoint
- type ApplianceList
- type ApplianceRequest
- type Auth
- type Catalog
- type CatalogActionResponse
- type CatalogList
- type CatalogRequest
- type CatalogType
- type CatalogTypeList
- type Client
- func (c *Client) ActionCatalog(catalog Catalog, actionType string) error
- func (c *Client) ActionDeployment(deployment Deployment, actionType string, force bool) error
- func (c *Client) ActionZone(zoneId string, action ZoneAction) error
- func (c *Client) ChangePassword(password, token string) (string, error)
- func (c *Client) CreateAppliance(applianceRequest ApplianceRequest) (Appliance, error)
- func (c *Client) CreateBillingAccount(apiAccessKey, description, directoryUri, enrollmentNumber, name, ... string) (string, error)
- func (c *Client) CreateCatalog(catalogRequest CatalogRequest) (Catalog, error)
- func (c *Client) CreateDeployment(deploymentRequest DeploymentRequest) (Deployment, error)
- func (c *Client) CreateMembership(membershipRequest MembershipRequest) (Membership, error)
- func (c *Client) CreateProject(projectRequest ProjectRequest) (Project, error)
- func (c *Client) CreateProvider(providerRequest ProviderRequest) (Provider, error)
- func (c *Client) CreateRegion(regionRequest RegionRequest) (Region, error)
- func (c *Client) CreateRegionConnection(regionId string, regionConnectionRequest RegionConnectionRequest) (RegionConnection, error)
- func (c *Client) CreateServer(server *Server) (string, error)
- func (c *Client) CreateTag(tagRequest TagRequest) (Tag, error)
- func (c *Client) CreateTagKey(tagKeyRequest TagKeyRequest) (TagKey, error)
- func (c *Client) CreateUser(userRequest UserRequest) (User, error)
- func (c *Client) CreateVolume(name string, sizeGiB int, zoneUri, projectUri string) (string, error)
- func (c *Client) CreateZone(zoneRequest ZoneRequest) (Zone, error)
- func (c *Client) CreateZoneConnection(id string, connectionRequest ConnectionRequest) (Connection, error)
- func (c *Client) DeleteAppliance(applianceId string) error
- func (c *Client) DeleteBillingAccount(id string) (string, error)
- func (c *Client) DeleteCatalog(catalogId string) error
- func (c *Client) DeleteDeployment(deploymentId string) error
- func (c *Client) DeleteMembershipByID(membershipId string) error
- func (c *Client) DeleteProject(projectId string) error
- func (c *Client) DeleteProvider(providerId string) error
- func (c *Client) DeleteRegion(regionId string) error
- func (c *Client) DeleteRegionConnection(regionId string) error
- func (c *Client) DeleteServer(serverID string, force bool) (string, error)
- func (c *Client) DeleteTag(tagId string) error
- func (c *Client) DeleteTagKey(tagKeyId string) error
- func (c *Client) DeleteUser(userId string) error
- func (c *Client) DeleteVolume(volumeID string) (string, error)
- func (c *Client) DeleteZone(zoneId string) error
- func (c *Client) DeleteZoneConnection(zoneId, connectionUuid string) error
- func (c *Client) Disconnect()
- func (c *Client) GetAccount(view string) (Account, error)
- func (c *Client) GetApplianceByID(id string) (Appliance, error)
- func (c *Client) GetAppliances() (ApplianceList, error)
- func (c *Client) GetAppliancesByName(name string) (ApplianceList, error)
- func (c *Client) GetAppliancesByNameAndRegion(name string, regionUri string) (ApplianceList, error)
- func (c *Client) GetAppliancesByRegion(regionUri string) (ApplianceList, error)
- func (c *Client) GetAzureLoginProperties() (string, error)
- func (c *Client) GetAzureProviderInfo(directoryUri, location string) (string, error)
- func (c *Client) GetAzureSubscriptions(directoryUri, location string) (string, error)
- func (c *Client) GetBillingAccount(id string) (string, error)
- func (c *Client) GetBillingAccounts(query, view string) (string, error)
- func (c *Client) GetCatalogByID(id, view string) (Catalog, error)
- func (c *Client) GetCatalogTypes() (CatalogTypeList, error)
- func (c *Client) GetCatalogs(userQuery, view string) (CatalogList, error)
- func (c *Client) GetConnectApp(os string) (string, error)
- func (c *Client) GetDeploymentByID(id string) (Deployment, error)
- func (c *Client) GetDeploymentByName(name string) (Deployment, error)
- func (c *Client) GetDeploymentConsole(deployment Deployment) (string, error)
- func (c *Client) GetDeploymentKubeConfig(deployment Deployment) (string, error)
- func (c *Client) GetDeployments(query string, userQuery string, sort string) (DeploymentList, error)
- func (c *Client) GetDeploymentsByName(name string) (DeploymentList, error)
- func (c *Client) GetEvents(resourceUri string) (string, error)
- func (c *Client) GetKeyPair(regionUri, projectUri string) (string, error)
- func (c *Client) GetMembershipByID(id string) (Membership, error)
- func (c *Client) GetMembershipRoleByName(name string) (MembershipRole, error)
- func (c *Client) GetMembershipRoles() (MembershipRoleList, error)
- func (c *Client) GetMemberships(query string) (MembershipList, error)
- func (c *Client) GetMembershipsByProject(projectUri string) (MembershipList, error)
- func (c *Client) GetMembershipsByRole(roleUri string) (MembershipList, error)
- func (c *Client) GetMembershipsByUser(userUri string) (MembershipList, error)
- func (c *Client) GetMembershipsByUserGroup(userGroupUri string) (MembershipList, error)
- func (c *Client) GetMetrics(resourceUri, category, groupBy, query, name string, periodStart, period string, ...) (string, error)
- func (c *Client) GetNetworkByID(id string) (Network, error)
- func (c *Client) GetNetworkByNameAndZoneURI(name, zoneUri string) (Network, error)
- func (c *Client) GetNetworkByZoneURI(zoneUri string) (Network, error)
- func (c *Client) GetNetworks(query string) (NetworkList, error)
- func (c *Client) GetProjectByID(id, view string) (Project, error)
- func (c *Client) GetProjectByName(name string) (Project, error)
- func (c *Client) GetProjects(userQuery, view string) (ProjectList, error)
- func (c *Client) GetProviderByID(id, view string, discover bool) (Provider, error)
- func (c *Client) GetProviderTypes() (ProviderTypeList, error)
- func (c *Client) GetProviders(query string) (ProviderList, error)
- func (c *Client) GetRate(rateID string) (string, error)
- func (c *Client) GetRates(resourceUri, effectiveForDate, effectiveDate, metricName string, active bool, ...) (string, error)
- func (c *Client) GetRegionByID(id, view string, discover bool) (Region, error)
- func (c *Client) GetRegionByName(name string) (Region, error)
- func (c *Client) GetRegionConnection(regionId string) (RegionConnection, error)
- func (c *Client) GetRegionConnectorImage(regionId string) (string, error)
- func (c *Client) GetRegions(query, view string) (RegionList, error)
- func (c *Client) GetRoles() (string, error)
- func (c *Client) GetServer(serverID string) (string, error)
- func (c *Client) GetServers(regionUri, applianceUri, zoneUri string) (string, error)
- func (c *Client) GetServiceByID(id string) (Service, error)
- func (c *Client) GetServiceByName(name string) (Service, error)
- func (c *Client) GetServiceTypeByID(id string) (ServiceType, error)
- func (c *Client) GetServiceTypes() (ServiceTypeList, error)
- func (c *Client) GetServices(query, userQuery string) (ServiceList, error)
- func (c *Client) GetSession(view string) (string, error)
- func (c *Client) GetSessionIdp(userName string) (string, error)
- func (c *Client) GetStatus() (string, error)
- func (c *Client) GetTagByID(id, view string) (Tag, error)
- func (c *Client) GetTagKeyByID(id, view string) (TagKey, error)
- func (c *Client) GetTagKeys(view string) (TagKeyList, error)
- func (c *Client) GetTags(view string) (TagList, error)
- func (c *Client) GetUserByID(id string) (User, error)
- func (c *Client) GetUserByName(name string) (User, error)
- func (c *Client) GetUsers(userQuery string) (UserList, error)
- func (c *Client) GetVersions() (string, error)
- func (c *Client) GetVirtualMachineProfileByID(id string) (VirtualMachineProfile, error)
- func (c *Client) GetVirtualMachineProfiles(query string) (VirtualMachineProfileList, error)
- func (c *Client) GetVirtualMachineProfilesByServiceAndZoneURI(serviceURI, zoneURI string) (VirtualMachineProfileList, error)
- func (c *Client) GetVirtualMachineProfilesByServiceURI(serviceURI string) (VirtualMachineProfileList, error)
- func (c *Client) GetVirtualMachineProfilesByZoneURI(zoneURI string) (VirtualMachineProfileList, error)
- func (c *Client) GetVolume(volumeID string) (string, error)
- func (c *Client) GetVolumes(query, view string) (string, error)
- func (c *Client) GetZoneApplianceImage(id string) (string, error)
- func (c *Client) GetZoneByID(id string) (Zone, error)
- func (c *Client) GetZoneByName(name string) (Zone, error)
- func (c *Client) GetZoneConnections(id, uuid string) (ConnectionList, error)
- func (c *Client) GetZoneTaskStatus(id string) (string, error)
- func (c *Client) GetZoneTypeResourceProfiles(zoneTypeId string) (ZoneTypeResourceProfileList, error)
- func (c *Client) GetZoneTypes() (ZoneTypeList, error)
- func (c *Client) GetZones(query, regionUri, providerUri, applianceUri, view string) (ZoneList, error)
- func (c *Client) ResetSingleUsePassword(email string) (string, error)
- func (c *Client) RestAPICall(method rest.Method, path string, queryParams map[string]string, ...) (string, error)
- func (c *Client) RestAPICallCustomHeaders(method rest.Method, customHeaders map[string]string, path string, ...) (string, error)
- func (c *Client) RestAPICallPatch(path string, queryParams map[string]string, values interface{}) (string, error)
- func (c *Client) UpdateAppliance(applianceId string, updates []*PatchOp) (Appliance, error)
- func (c *Client) UpdateAzureSubscription(directoryUri, location, subscriptionId string, patchPayload []*PatchOp) (string, error)
- func (c *Client) UpdateBillingAccount(id string, patchPayload []*PatchOp) (string, error)
- func (c *Client) UpdateCatalog(catalogId string, updates []*PatchOp) (Catalog, error)
- func (c *Client) UpdateDeployment(deploymentId string, updates []*PatchOp) (Deployment, error)
- func (c *Client) UpdateNetwork(networkId string, updates []*PatchOp) (Network, error)
- func (c *Client) UpdateProject(projectId string, updates ProjectRequest) (Project, error)
- func (c *Client) UpdateProvider(providerId string, updates []*PatchOp) (Provider, error)
- func (c *Client) UpdateRegion(regionId string, updates []*PatchOp) (Region, error)
- func (c *Client) UpdateServer(serverID string, patchPayload []*PatchOp) (string, error)
- func (c *Client) UpdateUser(userId string, updates UserRequest) (User, error)
- func (c *Client) UpdateVolume(volumeID, name string, sizeGiB int) (string, error)
- func (c *Client) UpdateZone(zoneId string, updates []*PatchOp) (Zone, error)
- func (c *Client) UpdateZoneConnection(zoneId, connectionUuid string, updates []*PatchOp) (Connection, error)
- type Cluster
- type Connection
- type ConnectionList
- type ConnectionRequest
- type Datastore
- type Deployment
- type DeploymentList
- type DeploymentNetworks
- type DeploymentRequest
- type Error
- type Host
- type KvmServer
- type Membership
- type MembershipList
- type MembershipRequest
- type MembershipRole
- type MembershipRoleList
- type Metric
- type NamedUri
- type NamedUriIdentifier
- type Network
- type NetworkList
- type PatchOp
- type Project
- type ProjectList
- type ProjectRequest
- type Provider
- type ProviderList
- type ProviderRequest
- type ProviderType
- type ProviderTypeList
- type Region
- type RegionConnection
- type RegionConnectionRequest
- type RegionList
- type RegionRequest
- type Resource
- type ResourceOps
- type Server
- type ServerExternalId
- type Service
- type ServiceList
- type ServiceType
- type ServiceTypeList
- type Tag
- type TagKey
- type TagKeyList
- type TagKeyRequest
- type TagList
- type TagRequest
- type User
- type UserList
- type UserRequest
- type VirtualMachineProfile
- type VirtualMachineProfileList
- type Zone
- type ZoneAction
- type ZoneList
- type ZoneRequest
- type ZoneType
- type ZoneTypeList
- type ZoneTypeResourceProfile
- type ZoneTypeResourceProfileList
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Account ¶
type Account struct { ID string `json:"id"` Name string `json:"name"` URI string `json:"uri"` Events []struct { NamedUriIdentifier ResourceUri string `json:"resourceUri"` UserId string `json:"userId"` Created string `json:"created"` Modified string `json:"modified"` } `json:"events"` Metrics []struct { Associations []struct { NamedUri Category string `json:"category"` } `json:"associations"` Count string `json:"count"` Description string `json:"description"` Name string `json:"name"` Resource *Resource `json:"resource"` ResourceUri string `json:"resourceUri"` Start int `json:"start"` Total int `json:"total"` Units string `json:"units"` Values []struct { End string `json:"end"` Start string `json:"start"` Value string `json:"value"` } `json:"values"` } `json:"metrics"` Created string `json:"created"` Modified string `json:"modified"` }
type AddressWithType ¶
type AddressWithType struct { Address string `json:"address"` AddressType string `json:"addressType"` }
AddressWithType defines JSON struct for { address, addressType }
type Appliance ¶
type Appliance struct { ID string `json:"id"` Name string `json:"name"` URI string `json:"uri"` Endpoint *ApplianceEndpoint `json:"endpoint"` L2Networks []struct { EthernetNetworkType string `json:"ethernetNetworkType"` Name string `json:"name"` Purpose string `json:"purpose"` URI string `json:"uri"` VlanID string `json:"vlanId"` } `json:"l2networks"` RegionUri string `json:"regionUri"` State string `json:"state"` Status string `json:"status"` Type string `json:"type"` Created string `json:"created"` Modified string `json:"modified"` }
type ApplianceEndpoint ¶
type ApplianceList ¶
type ApplianceRequest ¶
type ApplianceRequest struct { Name string `json:"name"` Endpoint *ApplianceEndpoint `json:"endpoint"` RegionURI string `json:"regionUri"` Type string `json:"type"` }
type Catalog ¶
type Catalog struct { ID string `json:"id"` Name string `json:"name"` URI string `json:"uri"` Created time.Time `json:"created"` Modified time.Time `json:"modified"` Status string `json:"status"` URL string `json:"url"` ServiceTypeURI string `json:"serviceTypeUri"` CatalogTypeURI string `json:"catalogTypeUri"` ServicesCount int `json:"servicesCount"` State string `json:"state"` Protected bool `json:"protected"` Message string `json:"message"` SupportedActions []string `json:"supportedActions"` }
type CatalogActionResponse ¶
type CatalogActionResponse struct {
Action string `json:"action"`
}
type CatalogList ¶
type CatalogRequest ¶
type CatalogType ¶
type CatalogTypeList ¶
type CatalogTypeList struct { Total int `json:"total"` Members []CatalogType `json:"members"` }
type Client ¶
type Client struct {
Auth *Auth
}
Client contains all the methods needed to interact with the OneSphere API use Connect() to return a *Client
func (*Client) ActionCatalog ¶
ActionCatalog Perform an Action on Catalog example actionType: "refresh"
func (*Client) ActionDeployment ¶
func (c *Client) ActionDeployment(deployment Deployment, actionType string, force bool) error
ActionDeployment Perform an Action on Deployment example actionType: "restart"
func (*Client) ActionZone ¶
func (c *Client) ActionZone(zoneId string, action ZoneAction) error
ActionZone Perform an Action on Zone
allowed ZoneAction.Type: reset | add-capacity | reduce-capacity allowed ZoneAction.ResourceOps.ResourceType: compute | storage
example ZoneAction:
ZoneAction{ Type: "add-capacity", ResourceOps: &ResourceOps{ ResourceType: "compute", ResourceCapacity: 2, }, }
func (*Client) ChangePassword ¶
func (*Client) CreateAppliance ¶
func (c *Client) CreateAppliance(applianceRequest ApplianceRequest) (Appliance, error)
CreateAppliance Creates Appliance and returns updated appliance
func (*Client) CreateBillingAccount ¶
func (*Client) CreateCatalog ¶
func (c *Client) CreateCatalog(catalogRequest CatalogRequest) (Catalog, error)
CreateCatalog Creates Catalog and returns updated Catalog
use GetCatalogTypes() for CatalogTypeURI
CatalogTypeURI should be one of: - /rest/catalog-types/aws-az - /rest/catalog-types/vcenter - /rest/catalog-types/kvm - /rest/catalog-types/helm-charts-repository - /rest/catalog-types/docker-hub - /rest/catalog-types/docker-registry - /rest/catalog-types/docker-trusted-registry - /rest/catalog-types/private-docker-registry - /rest/catalog-types/amazon-ecr - /rest/catalog-types/azure-container-registry - /rest/catalog-types/hpe-managed
func (*Client) CreateDeployment ¶
func (c *Client) CreateDeployment(deploymentRequest DeploymentRequest) (Deployment, error)
CreateDeployment Creates Deployment and returns updated deployment
func (*Client) CreateMembership ¶
func (c *Client) CreateMembership(membershipRequest MembershipRequest) (Membership, error)
CreateMembership Creates Membership and returns updated Membership
func (*Client) CreateProject ¶
func (c *Client) CreateProject(projectRequest ProjectRequest) (Project, error)
CreateProject Creates Project and returns updated Project
func (*Client) CreateProvider ¶
func (c *Client) CreateProvider(providerRequest ProviderRequest) (Provider, error)
CreateProvider Creates a new Master provider or Member provider and returns updated Provider use GetProviderTypes() for ProviderTypeURI
func (*Client) CreateRegion ¶
func (c *Client) CreateRegion(regionRequest RegionRequest) (Region, error)
CreateRegion Creates Region and returns updated Region
func (*Client) CreateRegionConnection ¶
func (c *Client) CreateRegionConnection(regionId string, regionConnectionRequest RegionConnectionRequest) (RegionConnection, error)
CreateRegionConnection Creates RegionConnection and returns updated RegionConnection
func (*Client) CreateTag ¶
func (c *Client) CreateTag(tagRequest TagRequest) (Tag, error)
CreateTag Creates Tag and returns updated Tag
func (*Client) CreateTagKey ¶
func (c *Client) CreateTagKey(tagKeyRequest TagKeyRequest) (TagKey, error)
CreateTagKey Creates TagKey and returns updated TagKey
func (*Client) CreateUser ¶
func (c *Client) CreateUser(userRequest UserRequest) (User, error)
CreateUser Creates User and returns updated User
func (*Client) CreateVolume ¶
func (*Client) CreateZone ¶
func (c *Client) CreateZone(zoneRequest ZoneRequest) (Zone, error)
CreateZone Creates Zone and returns updated zone
func (*Client) CreateZoneConnection ¶
func (c *Client) CreateZoneConnection(id string, connectionRequest ConnectionRequest) (Connection, error)
CreateZoneConnection Creates Connection and returns updated connection
func (*Client) DeleteAppliance ¶
DeleteAppliance Deletes Appliance
func (*Client) DeleteBillingAccount ¶
func (*Client) DeleteCatalog ¶
DeleteCatalog Deletes Catalog
func (*Client) DeleteDeployment ¶
DeleteDeployment Deletes Deployment
func (*Client) DeleteMembershipByID ¶
DeleteMembershipByID Deletes Membership by ID
func (*Client) DeleteProject ¶
DeleteProject Deletes Project
func (*Client) DeleteProvider ¶
DeleteProvider Deletes Provider
func (*Client) DeleteRegion ¶
DeleteRegion Deletes Region
func (*Client) DeleteRegionConnection ¶
DeleteRegionConnection Deletes RegionConnection
func (*Client) DeleteServer ¶
func (*Client) DeleteTagKey ¶
DeleteTagKey Deletes TagKey
func (*Client) DeleteUser ¶
DeleteUser Deletes User
func (*Client) DeleteZone ¶
DeleteZone Deletes Zone
func (*Client) DeleteZoneConnection ¶
DeleteZoneConnection Deletes Zone Connection
func (*Client) Disconnect ¶
func (c *Client) Disconnect()
func (*Client) GetAccount ¶
GetAccount returns global account information view : "full"
func (*Client) GetApplianceByID ¶
GetApplianceByID returns an Appliance by id
func (*Client) GetAppliances ¶
func (c *Client) GetAppliances() (ApplianceList, error)
GetAppliances returns a list of all Appliances
func (*Client) GetAppliancesByName ¶
func (c *Client) GetAppliancesByName(name string) (ApplianceList, error)
GetAppliancesByName returns a list of all Appliances by name or names
func (*Client) GetAppliancesByNameAndRegion ¶
func (c *Client) GetAppliancesByNameAndRegion(name string, regionUri string) (ApplianceList, error)
GetAppliancesByNameAndRegion returns a list of Appliances with optional name and regionUri name : "name of the desired appliance" regionUri : "set of appliances in this region"
func (*Client) GetAppliancesByRegion ¶
func (c *Client) GetAppliancesByRegion(regionUri string) (ApplianceList, error)
GetAppliancesByName returns a list of all Appliances by name or names
func (*Client) GetAzureLoginProperties ¶
func (*Client) GetAzureProviderInfo ¶
func (*Client) GetAzureSubscriptions ¶
func (*Client) GetBillingAccounts ¶
func (*Client) GetCatalogByID ¶
GetCatalogByID returns an Catalog by id example view: "full"
func (*Client) GetCatalogTypes ¶
func (c *Client) GetCatalogTypes() (CatalogTypeList, error)
GetCatalogTypes returns a list of all Catalog Types
func (*Client) GetCatalogs ¶
func (c *Client) GetCatalogs(userQuery, view string) (CatalogList, error)
GetCatalogs with optional userQuery and view leave filter blank to get all catalogs example userQuery: "dock" example view: "full"
func (*Client) GetConnectApp ¶
GetConnectApp allowed operating systems: ["windows", "mac"]
func (*Client) GetDeploymentByID ¶
func (c *Client) GetDeploymentByID(id string) (Deployment, error)
GetDeploymentByID Retrieve Deployment by ID
func (*Client) GetDeploymentByName ¶
func (c *Client) GetDeploymentByName(name string) (Deployment, error)
GetDeploymentByName returns first member of GetDeploymentsByName
func (*Client) GetDeploymentConsole ¶
func (c *Client) GetDeploymentConsole(deployment Deployment) (string, error)
GetDeploymentConsole returns a Deployment console url
func (*Client) GetDeploymentKubeConfig ¶
func (c *Client) GetDeploymentKubeConfig(deployment Deployment) (string, error)
GetDeploymentKubeConfig returns the kubeconfig of the deployment
func (*Client) GetDeployments ¶
func (c *Client) GetDeployments(query string, userQuery string, sort string) (DeploymentList, error)
GetDeployments with optional userQuery and sort leave filter blank to get all deployments example query: "zoneUri EQ /rest/zones/xxxx" example userQuery: "ubuntu"
func (*Client) GetDeploymentsByName ¶
func (c *Client) GetDeploymentsByName(name string) (DeploymentList, error)
func (*Client) GetKeyPair ¶
func (*Client) GetMembershipByID ¶
func (c *Client) GetMembershipByID(id string) (Membership, error)
GetMembershipByID returns a Membership by ID
func (*Client) GetMembershipRoleByName ¶
func (c *Client) GetMembershipRoleByName(name string) (MembershipRole, error)
GetMembershipRoleByName returns a list of all MembershipRole filtered by name
func (*Client) GetMembershipRoles ¶
func (c *Client) GetMembershipRoles() (MembershipRoleList, error)
GetMembershipRoles returns a list of all MembershipRoles
func (*Client) GetMemberships ¶
func (c *Client) GetMemberships(query string) (MembershipList, error)
GetMemberships with optional query filter valid queries: projectUri, userUri, userGroupUri, roleUri leave query blank to get all memberships example query: "projectUri EQ e0300a831e2740a4aad680cd89115845" example query: "userUri EQ e0300a831e2740a4aad680cd89115845" example query: "roleUri EQ e0300a831e2740a4aad680cd89115845"
func (*Client) GetMembershipsByProject ¶
func (c *Client) GetMembershipsByProject(projectUri string) (MembershipList, error)
GetMembershipByProject filters Memberships by projectUri
func (*Client) GetMembershipsByRole ¶
func (c *Client) GetMembershipsByRole(roleUri string) (MembershipList, error)
GetMembershipByRole filters Memberships by roleUri
func (*Client) GetMembershipsByUser ¶
func (c *Client) GetMembershipsByUser(userUri string) (MembershipList, error)
GetMembershipByUser filters Memberships by userUri
func (*Client) GetMembershipsByUserGroup ¶
func (c *Client) GetMembershipsByUserGroup(userGroupUri string) (MembershipList, error)
GetMembershipByUserGroup filters Memberships by userGroupUri
func (*Client) GetMetrics ¶
func (*Client) GetNetworkByID ¶
GetNetworkByID returns an Network by id
func (*Client) GetNetworkByNameAndZoneURI ¶
GetNetworkByNameAndZoneURI returns an Network by name and zoneUri
func (*Client) GetNetworkByZoneURI ¶
GetNetworkByZoneURI returns an Network by zoneUri
func (*Client) GetNetworks ¶
func (c *Client) GetNetworks(query string) (NetworkList, error)
GetNetworks with optional query leave query blank to get all networks example query: "zoneUri EQ /rest/zones/xxxx"
func (*Client) GetProjectByID ¶
GetProjectByID returns an Project by id example view: "full"
func (*Client) GetProjectByName ¶
GetProjectByName returns a Project by name
func (*Client) GetProjects ¶
func (c *Client) GetProjects(userQuery, view string) (ProjectList, error)
GetProjects with optional userQuery leave userQuery blank to get all projects example userQuery: "zoneUri EQ /rest/zones/xxxx" example view: "full"
func (*Client) GetProviderByID ¶
GetProviderByID returns an Provider by id
example view: "full" discover: Will return the merged set of regions from AWS and existing regions in Onesphere.
func (*Client) GetProviderTypes ¶
func (c *Client) GetProviderTypes() (ProviderTypeList, error)
GetProviderTypes returns a list of all Provider Types
func (*Client) GetProviders ¶
func (c *Client) GetProviders(query string) (ProviderList, error)
GetProviders returns ProviderList with optional query AWS credentials are not included when listing providers. leave filter blank to get all providers example query: "providerTypeUri EQ /rest/provider-types/aws"
func (*Client) GetRegionByID ¶
GetRegionByID returns a Provider by id example view: "full" discover: Will return child providers from aws.
func (*Client) GetRegionByName ¶
GetRegionByName Retrieve Region by Name
func (*Client) GetRegionConnection ¶
func (c *Client) GetRegionConnection(regionId string) (RegionConnection, error)
func (*Client) GetRegionConnectorImage ¶
GetRegionConnectorImage returns generated connector-image url
func (*Client) GetRegions ¶
func (c *Client) GetRegions(query, view string) (RegionList, error)
GetRegions returns RegionList with optional query and view leave query blank to get all regions example query: "providerUri EQ /rest/providers/xxxx" example view: "full"
func (*Client) GetServers ¶
func (*Client) GetServiceByID ¶
GetServiceByID returns a Service by ID
func (*Client) GetServiceByName ¶
GetServiceByName returns a Service by Name
func (*Client) GetServiceTypeByID ¶
func (c *Client) GetServiceTypeByID(id string) (ServiceType, error)
GetServiceTypeByID returns a Service Type by ID
func (*Client) GetServiceTypes ¶
func (c *Client) GetServiceTypes() (ServiceTypeList, error)
GetServiceTypes returns a list of all Service Types
func (*Client) GetServices ¶
func (c *Client) GetServices(query, userQuery string) (ServiceList, error)
GetServices returns a list of all Services with optional query and userQuery leave filter blank to get all services example query: "serviceTypeUri EQ /rest/service-types/zone" example userQuery: "kub"
func (*Client) GetTagByID ¶
GetTagByID returns an Tag by id example view: "full"
func (*Client) GetTagKeyByID ¶
GetTagKeyByID returns an TagKey by id example view: "full"
func (*Client) GetTagKeys ¶
func (c *Client) GetTagKeys(view string) (TagKeyList, error)
GetTagKeys with optional view example view: "full"
func (*Client) GetUserByID ¶
GetUserByID returns a User by id
func (*Client) GetUserByName ¶
GetUserByID returns a User by name
func (*Client) GetUsers ¶
GetUsers with optional userQuery leave userQuery blank to get all users example userQuery: "jon"
func (*Client) GetVersions ¶
func (*Client) GetVirtualMachineProfileByID ¶
func (c *Client) GetVirtualMachineProfileByID(id string) (VirtualMachineProfile, error)
GetVirtualMachineProfileByID returns a VirtualMachineProfile by ID
func (*Client) GetVirtualMachineProfiles ¶
func (c *Client) GetVirtualMachineProfiles(query string) (VirtualMachineProfileList, error)
GetVirtualMachineProfiles returns VirtualMachineProfileList with optional query for zoneUri and serviceUri leaving the query blank will return an empty VirtualMachineProfileList example query for serviceUri: "serviceUri EQ /rest/services/2F8bbc7abe-2ae1-a366-a4dd-f065618063a6" example query for zoneUri: "zoneUri EQ /rest/zones/b1d0b94b-b3e2-459f-95ed-a1b4d4645338" example query for both: "serviceUri EQ /rest/services/2F8bbc7abe-2ae1-a366-a4dd-f065618063a6 AND zoneUri EQ /rest/zones/b1d0b94b-b3e2-459f-95ed-a1b4d4645338"
func (*Client) GetVirtualMachineProfilesByServiceAndZoneURI ¶
func (c *Client) GetVirtualMachineProfilesByServiceAndZoneURI(serviceURI, zoneURI string) (VirtualMachineProfileList, error)
GetVirtualMachineProfilesByServiceAndZoneURI returns VirtualMachineProfileList by zoneUri example: client.GetVirtualMachineProfilesByServiceAndZoneURI("/rest/services/2F8bbc7abe-2ae1-a366-a4dd-f065618063a6", "/rest/zones/b1d0b94b-b3e2-459f-95ed-a1b4d4645338")
func (*Client) GetVirtualMachineProfilesByServiceURI ¶
func (c *Client) GetVirtualMachineProfilesByServiceURI(serviceURI string) (VirtualMachineProfileList, error)
GetVirtualMachineProfilesByServiceURI returns VirtualMachineProfileList by serviceUri example: client.GetVirtualMachineProfilesByServiceURI("/rest/services/2F8bbc7abe-2ae1-a366-a4dd-f065618063a6")
func (*Client) GetVirtualMachineProfilesByZoneURI ¶
func (c *Client) GetVirtualMachineProfilesByZoneURI(zoneURI string) (VirtualMachineProfileList, error)
GetVirtualMachineProfilesByZoneURI returns VirtualMachineProfileList by zoneUri example: client.GetVirtualMachineProfilesByZoneURI("/rest/zones/b1d0b94b-b3e2-459f-95ed-a1b4d4645338")
func (*Client) GetVolumes ¶
view: "full"
func (*Client) GetZoneApplianceImage ¶
GetZoneApplianceImage Retrieve Zone Appliance Image URI by Zone.ID
func (*Client) GetZoneByID ¶
GetZoneByID Retrieve Zone by ID
func (*Client) GetZoneByName ¶
GetZoneByID Retrieve Zone by Name
func (*Client) GetZoneConnections ¶
func (c *Client) GetZoneConnections(id, uuid string) (ConnectionList, error)
GetZoneConnections with optional uuid filter leave uuid blank to get all connections
func (*Client) GetZoneTaskStatus ¶
GetZoneTaskStatus Retrieve Zone Appliance Image URI by Zone.ID
func (*Client) GetZoneTypeResourceProfiles ¶
func (c *Client) GetZoneTypeResourceProfiles(zoneTypeId string) (ZoneTypeResourceProfileList, error)
GetZoneTypeResourceProfiles returns a ZoneTypeResourceProfileList
func (*Client) GetZoneTypes ¶
func (c *Client) GetZoneTypes() (ZoneTypeList, error)
GetZoneTypes returns a list of all Zone Types
func (*Client) GetZones ¶
func (c *Client) GetZones(query, regionUri, providerUri, applianceUri, view string) (ZoneList, error)
GetZones with optional query, and filters by regionUri, providerUri, applianceUri
leave query and filter blank to get all zones
query supports equality comparison against one or more properties using a "name EQ value" syntax. Multiple comparisons can be combined using a "name1 EQ value1 AND name2 EQ value2" syntax.
example query: "providerUri EQ /rest/providers/xxxx"
example view: "full"
func (*Client) ResetSingleUsePassword ¶
func (*Client) RestAPICall ¶
func (*Client) RestAPICallCustomHeaders ¶
func (*Client) RestAPICallPatch ¶
func (*Client) UpdateAppliance ¶
UpdateAppliance using []*PatchOp and returns updated appliance on success
func (*Client) UpdateAzureSubscription ¶
func (c *Client) UpdateAzureSubscription(directoryUri, location, subscriptionId string, patchPayload []*PatchOp) (string, error)
UpdateAzureSubscription allowed Ops in patchPayload: - add - replace
func (*Client) UpdateBillingAccount ¶
UpdateBillingAccount sends PATCH with Op: "add|replace|remove"
func (*Client) UpdateCatalog ¶
UpdateCatalog using []*PatchOp returns updated catalog on success
Allowed fields for PATCH of catalogs ¶
Path: /name Op: add | replace
Path: /password Op: add
Path: /accessKey Op: add
Path: /secretKey Op: add
Path: /state Op: add | replace
func (*Client) UpdateDeployment ¶
func (c *Client) UpdateDeployment(deploymentId string, updates []*PatchOp) (Deployment, error)
UpdateDeployment using []*PatchOp returns updated deployment on success
func (*Client) UpdateNetwork ¶
UpdateNetwork using []*PatchOp returns updated network on success
Allowed Ops for PATCH of networks: add | replace | remove
example:
Op: add Path: projectUris Value: /rest/projects/abc
func (*Client) UpdateProject ¶
func (c *Client) UpdateProject(projectId string, updates ProjectRequest) (Project, error)
UpdateProject using ProjectRequest returns updated project on success
func (*Client) UpdateProvider ¶
UpdateProvider using []*PatchOp returns updated provider on success
Allowed Ops for PATCH of providers: add | replace | remove
example:
Op: replace Path: /name Value: new name
func (*Client) UpdateRegion ¶
UpdateRegion using []*PatchOp returns updated region on success
UpdateRegion only supports provider type(/rest/provider-types/ncs).
Allowed fields for PATCH of NCS provider type: /name | /location Allowed OPs for PATCH of NCS provider type: add | replace
Path: /name Op: add
Path: /location Op: replace
func (*Client) UpdateUser ¶
func (c *Client) UpdateUser(userId string, updates UserRequest) (User, error)
UpdateUser using UserRequest returns updated user on success
func (*Client) UpdateVolume ¶
func (*Client) UpdateZone ¶
UpdateZone using []*PatchOp returns updated zone on success
Allowed Ops for PATCH of networks: add | replace | remove
example:
Op: "add" Path: "/inTransitClusters"
Value: []struct { ID string `json:"id"` State string `json:"state"` }{
{ ID: "domain-c51", State: "Enabled", }, }
example:
Op: "add" Path: "/networkSettings"
Value: struct { NcsManagementNetwork string `json:"ncsManagementNetwork"` EsxManagementNetwork string `json:"esxManagementNetwork"` StorageNetwork string `json:"storageNetwork"` MovementNetwork string `json:"movementNetwork"` ProductionNetwork []string `json:"productionNetwork"` } {
NcsManagementNetwork: "net1", EsxManagementNetwork: "net2", StorageNetwork: "net3", MovementNetwork: "net4", ProductionNetwork: []string{ "net5", "net6" }, }
example:
Op: "add" Path: "/networkSettings"
Value: []struct { ServerURI string `json:"serverUri"` State string `json:"state"` Roles []string `json:"roles"` }{
{ ServerURI: "/rest/servers/2b5a8db7-e145-4ef9-b7f2-9b2d45976cd3", State: "Enabled", Roles: []string{ "ImageLibrary" }, }, }
func (*Client) UpdateZoneConnection ¶
func (c *Client) UpdateZoneConnection(zoneId, connectionUuid string, updates []*PatchOp) (Connection, error)
UpdateZoneConnection using []*PatchOp returns updated Connection on success
Allowed Ops for PATCH of networks: add | replace | remove
type Cluster ¶
type Cluster struct { Created time.Time `json:"created"` ID string `json:"id"` Name string `json:"name"` Modified time.Time `json:"modified"` Status string `json:"status"` State string `json:"state"` Error *Error `json:"error"` Hosts []*Host `json:"hosts"` Datastores []*Datastore `json:"datastores"` }
type Connection ¶
type Connection struct { ID string `json:"id"` UUID string `json:"uuid"` Name string `json:"name"` Location struct { IPAddress string `json:"ipAddress"` Username string `json:"username"` Password string `json:"password"` Port int `json:"port"` } `json:"location"` State string `json:"state"` URI string `json:"uri"` }
type ConnectionList ¶
type ConnectionList struct { Total int `json:"total"` Members []Connection `json:"members"` }
type ConnectionRequest ¶
type Deployment ¶
type Deployment struct { ID string `json:"id"` Name string `json:"name"` URI string `json:"uri"` ZoneURI string `json:"zoneUri"` Zone *NamedUriIdentifier `json:"zone"` RegionURI string `json:"regionUri"` ServiceURI string `json:"serviceUri"` Service *NamedUriIdentifier `json:"service"` ServiceTypeURI string `json:"serviceTypeUri"` Version string `json:"version"` Status string `json:"status"` State string `json:"state"` ProjectURI string `json:"projectUri"` DeploymentEndpoints []*AddressWithType `json:"deploymentEndpoints"` AppDeploymentInfo string `json:"appDeploymentInfo"` HasConsole bool `json:"hasConsole"` CloudPlatformID string `json:"cloudPlatformId"` Created string `json:"created"` Modified string `json:"modified"` }
type DeploymentList ¶
type DeploymentList struct { Total int `json:"total"` Count int `json:"count"` Start int `json:"start"` PrevPageURI utils.Nstring `json:"prevPageUri,omitempty"` NextPageURI utils.Nstring `json:"nextPageUri,omitempty"` URI utils.Nstring `json:"uri,omitempty"` Members []Deployment `json:"members"` }
deploymentList structure
type DeploymentNetworks ¶
type DeploymentNetworks struct {
NetworkURI string `json:"networkUri,omitempty"`
}
type DeploymentRequest ¶
type DeploymentRequest struct { AssignExternalIP string `json:"assignExternalIP,omitempty"` Firewall []struct { AllowedIPs string `json:"allowedIPs"` Ports []string `json:"ports"` } `json:"firewall"` HTTPProxy string `json:"httpProxy,omitempty"` HTTPProxyPassword string `json:"httpProxyPassword,omitempty"` HTTPProxyUserName string `json:"httpProxyUserName,omitempty"` Image string `json:"image,omitempty"` K8SDeploymentRegion string `json:"k8sDeploymentRegion,omitempty"` K8SDomainURI string `json:"k8sDomainUri,omitempty"` K8SMasterFlavor string `json:"k8sMasterFlavor,omitempty"` K8SNumMasters string `json:"k8sNumMasters,omitempty"` K8SWorkerFlavor string `json:"k8sWorkerFlavor,omitempty"` K8SnumWorkers string `json:"k8snumWorkers,omitempty"` Name string `json:"name,omitempty"` Networks []DeploymentNetworks `json:"networks,omitempty"` Parameters string `json:"parameters,omitempty"` ProjectURI utils.Nstring `json:"projectUri,omitempty"` PublicKey string `json:"publicKey,omitempty"` RegionURI utils.Nstring `json:"regionUri,omitempty"` ServiceInput string `json:"serviceInput,omitempty"` ServiceURI utils.Nstring `json:"serviceUri,omitempty"` UserData string `json:"userData,omitempty"` Version string `json:"version,omitempty"` VirtualMachineProfileURI utils.Nstring `json:"virtualMachineProfileUri,omitempty"` ZoneURI string `json:"zoneUri,omitempty"` }
type Error ¶
type Error struct { Message string `json:"message"` Details string `json:"details"` RecommendedActions []string `json:"recommendedActions"` NestedErrors string `json:"nestedErrors"` ErrorSource string `json:"errorSource"` ErrorCode string `json:"errorCode"` Data string `json:"data"` CanForce bool `json:"canForce"` }
type Host ¶
type Host struct { ID string `json:"id"` Name string `json:"name"` OsName string `json:"osName"` OsVersion string `json:"osVersion"` TotalMemoryGb float32 `json:"totalMemoryGb"` FreeMemoryGb float32 `json:"freeMemoryGb"` TotalCPUGhz float32 `json:"totalCpuGhz"` FreeCPUGhz float32 `json:"freeCpuGhz"` Datastores []string `json:"datastores"` }
type KvmServer ¶
type KvmServer struct { ServerURI string `json:"serverUri"` Name string `json:"name"` Created time.Time `json:"created"` Modified time.Time `json:"modified"` Status string `json:"status"` State string `json:"state"` Datastores []*Datastore `json:"datastores"` Host *Host `json:"host"` Roles []string `json:"roles"` Error *Error `json:"error"` }
type Membership ¶
type MembershipList ¶
type MembershipList struct { Total int `json:"total"` Members []Membership `json:"members"` }
type MembershipRequest ¶
type MembershipRequest = Membership
type MembershipRole ¶
type MembershipRole = NamedUriIdentifier
type MembershipRoleList ¶
type MembershipRoleList struct { Total int `json:"total"` Members []MembershipRole `json:"members"` }
type Metric ¶
type Metric struct { ResourceURI string `json:"resourceUri"` Resource *Resource `json:"resource"` Name string `json:"name"` Units string `json:"units"` Description string `json:"description"` Values []struct { Value int `json:"value"` Start time.Time `json:"start"` End time.Time `json:"end"` } `json:"values"` Total int `json:"total"` Start int `json:"start"` Count int `json:"count"` Associations []struct { NamedUri Category string `json:"category"` } `json:"associations"` }
type NamedUriIdentifier ¶
type NamedUriIdentifier struct { ID string `json:"id"` Name string `json:"name"` URI string `json:"uri"` }
NamedUriIdentifier defines JSON struct for { id, name, uri }
type Network ¶
type Network struct { ID string `json:"id"` Name string `json:"name"` URI string `json:"uri"` Created string `json:"created"` IpamType string `json:"ipamType"` Modified string `json:"modified"` ProjectUris []string `json:"projectUris"` Subnets []struct { Cidr string `json:"cidr"` DNS1 string `json:"dns1"` DNS2 string `json:"dns2"` Gateway string `json:"gateway"` IPPools []struct { EndIP string `json:"endIP"` Purpose string `json:"purpose"` StartIP string `json:"startIP"` } `json:"ipPools"` } `json:"subnets"` Vlan int `json:"vlan"` ZoneURI string `json:"zoneUri"` }
type NetworkList ¶
type Project ¶
type Project struct { ID string `json:"id"` Name string `json:"name"` URI string `json:"uri"` Created string `json:"created"` Deployments struct { Members []struct { NamedUriIdentifier ActiveUsers []struct { Email string `json:"email"` IsLocal string `json:"isLocal"` Name string `json:"name"` Role string `json:"role"` URI string `json:"uri"` } `json:"activeUsers"` ClusterURI string `json:"clusterUri"` CPUCount int `json:"cpuCount"` CPUGhz int `json:"cpuGhz"` Created string `json:"created"` DiskSizeGB int `json:"diskSizeGB"` Endpoints []struct { AddressWithType Name string `json:"name"` } `json:"endpoints"` ErrorMessage string `json:"errorMessage"` Firewall []struct { AllowedIPs string `json:"allowedIPs"` Ports []int `json:"ports"` } `json:"firewall"` HasConsole bool `json:"hasConsole"` MemorySizeGB int `json:"memorySizeGB"` Modified string `json:"modified"` ProjectURI string `json:"projectUri"` Region *NamedUriIdentifier `json:"region"` RegionURI string `json:"regionUri"` Service struct { NamedUriIdentifier Icon string `json:"icon"` Version string `json:"version"` } `json:"service"` ServiceURI string `json:"serviceUri"` State string `json:"state"` Status string `json:"status"` VirtualMachineProfileURI string `json:"virtualMachineProfileUri"` VolumeURIs []string `json:"volumeURIs"` Volumes []struct { NamedUriIdentifier SizeGiB string `json:"sizeGiB"` Status string `json:"status"` } `json:"volumes"` ZoneURI string `json:"zoneUri"` } `json:"members"` Total int `json:"total"` } `json:"deployments"` Modified string `json:"modified"` Protected bool `json:"protected"` TagUris []string `json:"tagUris"` }
type ProjectList ¶
type ProjectRequest ¶
type Provider ¶
type Provider struct { ID string `json:"id"` Name string `json:"name"` URI string `json:"uri"` ProviderTypeURI string `json:"providerTypeUri"` Status string `json:"status"` State string `json:"state"` AccessKey string `json:"accessKey"` SecretKey string `json:"secretKey"` PaymentProvider bool `json:"paymentProvider"` S3CostBucket string `json:"s3CostBucket"` SubscriptionID string `json:"subscriptionId"` DirectoryURI string `json:"directoryUri"` TenantID string `json:"tenantId"` UniqueName string `json:"uniqueName"` FamilyName string `json:"familyName"` GivenName string `json:"givenName"` ClientID string `json:"clientID"` ClientSecret string `json:"clientSecret"` Children []struct { ID string `json:"id"` Name string `json:"name"` URI string `json:"uri"` ProviderTypeURI string `json:"providerTypeUri"` Status string `json:"status"` State string `json:"state"` } `json:"children"` BillingAccountURI string `json:"billingAccountUri"` ProjectUris []string `json:"projectUris"` Regions []*Region `json:"regions"` Metrics []*Metric `json:"metrics"` Created time.Time `json:"created"` Modified time.Time `json:"modified"` }
type ProviderList ¶
type ProviderRequest ¶
type ProviderRequest struct { ID string `json:"id"` ProviderTypeURI string `json:"providerTypeUri"` AccessKey string `json:"accessKey"` SecretKey string `json:"secretKey"` PaymentProvider bool `json:"paymentProvider"` S3CostBucket string `json:"s3CostBucket"` MasterURI string `json:"masterUri"` SubscriptionID string `json:"subscriptionId"` DirectoryURI string `json:"directoryUri"` TenantID string `json:"tenantId"` UniqueName string `json:"uniqueName"` FamilyName string `json:"familyName"` GivenName string `json:"givenName"` BillingAccountURI string `json:"billingAccountUri"` State string `json:"state"` }
type ProviderType ¶
type ProviderType struct { Created time.Time `json:"created"` ID string `json:"id"` Logo string `json:"logo"` Metrics []struct { ResourceURI string `json:"resourceUri"` Resource *Resource `json:"resource"` Name string `json:"name"` Units string `json:"units"` Description string `json:"description"` Values []struct { Value int `json:"value"` Start time.Time `json:"start"` End time.Time `json:"end"` } `json:"values"` Total int `json:"total"` Start int `json:"start"` Count int `json:"count"` Associations []struct { Category string `json:"category"` Name string `json:"name"` URI string `json:"uri"` } `json:"associations"` } `json:"metrics"` Modified time.Time `json:"modified"` Name string `json:"name"` URI string `json:"uri"` }
type ProviderTypeList ¶
type ProviderTypeList struct { Total int `json:"total"` Members []ProviderType `json:"members"` }
type Region ¶
type Region struct { ID string `json:"id"` Metrics []*Metric `json:"metrics"` Created time.Time `json:"created"` Modified time.Time `json:"modified"` Name string `json:"name"` Location struct { Latitude float32 `json:"latitude"` Longitude float32 `json:"longitude"` } `json:"location"` ProviderURI string `json:"providerUri"` Provider *Provider `json:"provider"` Zones []*Zone `json:"zones"` Status string `json:"status"` State string `json:"state"` URI string `json:"uri"` }
type RegionConnection ¶
type RegionConnection struct { EndpointUUID string `json:"endpointUuid"` Name string `json:"name"` Location struct { IPAddress string `json:"ipAddress"` Username string `json:"username"` Password string `json:"password"` Port int `json:"port"` } `json:"location"` State string `json:"state"` URI string `json:"uri"` }
type RegionConnectionRequest ¶
type RegionConnectionRequest struct { EndpointUUID string `json:"endpointUuid"` Name string `json:"name"` Location struct { IPAddress string `json:"ipAddress"` Username string `json:"username"` Password string `json:"password"` Port int `json:"port"` } `json:"location"` State string `json:"state"` }
type RegionList ¶
type RegionRequest ¶
type Resource ¶
type Resource struct { NamedUri Value string `json:"value"` Project NamedUri `json:"project"` Zone struct { NamedUri Region struct { NamedUri Provider struct { NamedUri ProviderType struct { Name string `json:"name"` Uri string `json:"uri"` } `json:"providerType"` } `json:"provider"` } `json:"region"` } `json:"zone"` }
type ResourceOps ¶
type Server ¶
type Server struct { ApplianceUri string `json:"applianceUri"` CoreCount int `json:"coreCount"` CoreSpeedMHz int `json:"coreSpeedMHz"` CpuModel string `json:"cpuModel"` ExternalIds []*ServerExternalId MemoryGB int `json:"memoryGB"` Name string `json:"name"` ProcessorCount int `json:"processorCount"` ProjectUri string `json:"projectUri"` RegionUri string `json:"regionUri"` ServerModel string `json:"serverModel"` State string `json:"state"` // "Enabling|Enabled|Disabling|Disabled" ZoneUri string `json:"zoneUri"` }
type ServerExternalId ¶
type Service ¶
type Service = NamedUriIdentifier
type ServiceList ¶
type ServiceType ¶
type ServiceType = NamedUriIdentifier
type ServiceTypeList ¶
type ServiceTypeList struct { Total int `json:"total"` Members []ServiceType `json:"members"` }
type TagKeyList ¶
type TagKeyRequest ¶
type TagKeyRequest struct {
Name string `json:"name"`
}
type TagRequest ¶
type UserRequest ¶
type VirtualMachineProfile ¶
type VirtualMachineProfile struct { ID string `json:"id"` Name string `json:"name"` URI string `json:"uri"` RegionURI string `json:"regionUri"` ZoneURI string `json:"zoneUri"` CPUCount int `json:"cpuCount"` MemorySizeGB int `json:"memorySizeGB"` DiskSizeGB int `json:"diskSizeGB"` Created time.Time `json:"created"` Modified time.Time `json:"modified"` }
type VirtualMachineProfileList ¶
type VirtualMachineProfileList struct { ID string `json:"id"` Name string `json:"name"` URI string `json:"uri"` Description string `json:"description"` RegionURI string `json:"regionUri"` ZoneURI string `json:"zoneUri"` CPUCount int `json:"cpuCount"` MemorySizeGB int `json:"memorySizeGB"` DiskSizeGB int `json:"diskSizeGB"` Created time.Time `json:"created"` Modified time.Time `json:"modified"` }
type Zone ¶
type Zone struct { Created time.Time `json:"created"` ID string `json:"id"` Metrics []*Metric `json:"metrics"` Modified time.Time `json:"modified"` Name string `json:"name"` ProviderURI string `json:"providerUri"` RegionURI string `json:"regionUri"` Error *Error `json:"error"` Status string `json:"status"` State string `json:"state"` CurrentTasks []struct { TaskName string `json:"taskName"` TaskState string `json:"taskState"` TaskStatus string `json:"taskStatus"` } `json:"currentTasks"` Clusters []*Cluster `json:"clusters"` InTransitClusters []*Cluster `json:"inTransitClusters"` EsxLcmTask struct { URI string `json:"uri"` Name string `json:"name"` Type string `json:"type"` UUID string `json:"uuid"` ParentID string `json:"parentId"` ChildTasks []string `json:"childTasks"` PercentComplete int `json:"percentComplete"` ProgressUpdates []struct { StatusUpdate string `json:"StatusUpdate"` TimeStamp time.Time `json:"TimeStamp"` } `json:"ProgressUpdates"` AssociatedResourceInstanceURI string `json:"associatedResourceInstanceUri"` AssociatedResourceInstanceID string `json:"associatedResourceInstanceId"` AssociatedResourceInstanceType string `json:"associatedResourceInstanceType"` State string `json:"state"` Status string `json:"status"` Error *Error `json:"error"` TaskFailed bool `json:"taskFailed"` Created string `json:"created"` Modified string `json:"modified"` } `json:"esxLcmTask"` NetworkSettings struct { NcsManagementNetwork string `json:"ncsManagementNetwork"` EsxManagementNetwork string `json:"esxManagementNetwork"` StorageNetwork string `json:"storageNetwork"` VMotionNetwork string `json:"vMotionNetwork"` ProductionNetwork []string `json:"productionNetwork"` PhysicalNetworks []struct { Name string `json:"name"` NetworkType string `json:"networkType"` } `json:"physicalNetworks"` } `json:"networkSettings"` VcenterSettings struct { IPAddress string `json:"ipAddress"` Username string `json:"username"` Password string `json:"password"` Port int `json:"port"` } `json:"vcenterSettings"` Managed bool `json:"managed"` URI string `json:"uri"` ZoneTypeURI string `json:"zoneTypeUri"` ProjectUris []string `json:"projectUris"` Projects []*Project `json:"projects"` ResourceProfile struct { ID string `json:"id"` Name string `json:"name"` Description string `json:"description"` } `json:"resourceProfile"` Default bool `json:"default"` ApplianceURI string `json:"applianceUri"` KvmServers []*KvmServer `json:"kvmServers"` InTransitKvmServers []KvmServer `json:"inTransitKvmServers"` }
type ZoneAction ¶
type ZoneAction struct { Type string `json:"type"` ResourceOps *ResourceOps `json:"resourceOps"` }
type ZoneRequest ¶
type ZoneRequest struct { Name string `json:"name"` ProviderURI string `json:"providerUri"` RegionURI string `json:"regionUri"` ZoneTypeURI string `json:"zoneTypeUri"` ApplianceURI string `json:"applianceUri"` NetworkSettings struct { NcsManagementNetwork string `json:"ncsManagementNetwork"` EsxManagementNetwork string `json:"esxManagementNetwork"` StorageNetwork string `json:"storageNetwork"` VMotionNetwork string `json:"vMotionNetwork"` ProductionNetwork []string `json:"productionNetwork"` PhysicalNetworks []struct { Name string `json:"name"` NetworkType string `json:"networkType"` } `json:"physicalNetworks"` } `json:"networkSettings"` VcenterSettings struct { IPAddress string `json:"ipAddress"` Username string `json:"username"` Password string `json:"password"` Port int `json:"port"` } `json:"vcenterSettings"` ResourceProfile struct { ID string `json:"id"` Name string `json:"name"` Description string `json:"description"` } `json:"resourceProfile"` ResourceCapacity int `json:"resourceCapacity"` Rates []struct { MetricName string `json:"metricName"` RateValue int `json:"rateValue"` } `json:"rates"` }
type ZoneTypeList ¶
type ZoneTypeResourceProfile ¶
type ZoneTypeResourceProfileList ¶
type ZoneTypeResourceProfileList struct { Total int `json:"total"` Members []ZoneTypeResourceProfile `json:"members"` }
Source Files ¶
- account.go
- appliance.go
- catalog.go
- catalog_types.go
- cluster.go
- connection.go
- datastore.go
- deployment.go
- error.go
- host.go
- kvm_server.go
- membership.go
- membership_roles.go
- metric.go
- network.go
- onesphere.go
- patch_op.go
- project.go
- provider.go
- provider_types.go
- region.go
- resource.go
- server.go
- service.go
- service_type.go
- tag.go
- tag_key.go
- user.go
- virtual_machine_profile.go
- zone.go
- zone_type.go
Directories ¶
Path | Synopsis |
---|---|
FMT Logger - a very simplistic implementation for logger - everything is printed through fmt - stores history with sensitive data scrubbing
|
FMT Logger - a very simplistic implementation for logger - everything is printed through fmt - stores history with sensitive data scrubbing |