Documentation ¶
Index ¶
- Constants
- Variables
- func Provider() terraform.ResourceProvider
- type AWSInstanceMetadata
- type Client
- func (c *Client) AzureAuthorize() (autorest.Authorizer, error)
- func (c *Client) CallAMIGet(occmDetails createAWSOCCMDetails) (string, error)
- func (c *Client) CallAPIMethod(method string, baseURL string, params map[string]interface{}, token string, ...) (int, []byte, string, error)
- func (c *Client) CallAWSDescribeInstanceAttribute(occmDetails createAWSOCCMDetails) (bool, error)
- func (c *Client) CallAWSGetReservationsForRegion(region string) ([]ec2.Instance, error)
- func (c *Client) CallAWSInstanceCreate(occmDetails createAWSOCCMDetails) (string, error)
- func (c *Client) CallAWSInstanceGet(occmDetails createAWSOCCMDetails) ([]ec2.Instance, error)
- func (c *Client) CallAWSInstanceTerminate(occmDetails deleteOCCMDetails) error
- func (c *Client) CallAWSInstanceUpdate(occmDetails createAWSOCCMDetails) error
- func (c *Client) CallAWSRegionGet(occmDetails createAWSOCCMDetails) ([]string, error)
- func (c *Client) CallAWSTagCreate(occmDetails createAWSOCCMDetails) error
- func (c *Client) CallAWSTagDelete(occmDetails createAWSOCCMDetails) error
- func (c *Client) CallDeleteAzureVM(occmDetails deleteOCCMDetails) error
- func (c *Client) CallDeployAzureVM(occmDetails createOCCMDetails) (string, error)
- func (c *Client) CallGetAzureVM(occmDetails createOCCMDetails) (string, error)
- func (c *Client) CallVNetGet(subscriptionID string, resourceGroup string) (string, string, error)
- func (c *Client) CallVNetGetCidr(subscriptionID string, resourceGroup string, vnet string) (string, error)
- func (c *Client) CallVPCGet(subnet string, region string) (string, error)
- func (c *Client) GetRefreshToken() string
- func (c *Client) GetServiceCredential() (string, string)
- func (c *Client) GetSimulator() bool
- func (c *Client) SetRefreshToken(refreshToken string)
- func (c *Client) SetServiceCredential(SaSecretKey string, SaClientID string)
- func (c *Client) SetSimulator(simulator bool)
- type ExportPolicyInfo
- type ExportPolicyInfoResponse
- type ExportPolicyRule
- type OCCMMGCPResult
- type OCCMMResult
Constants ¶
const GiBToBytes = 1024 * 1024 * 1024
GiBToBytes converting GB to bytes
const TiBToGiB = 1024
TiBToGiB converting TiB to GiB
Variables ¶
var AWSLicenseTypes = []string{"cot-standard-paygo", "cot-premium-paygo", "cot-explore-paygo", "cot-premium-byol",
"ha-cot-standard-paygo", "ha-cot-premium-paygo", "ha-cot-premium-byol", "ha-cot-explore-paygo", "capacity-paygo",
"ha-capacity-paygo"}
AWSLicenseTypes is the AWS License types
var AzureLicenseTypes = []string{"azure-cot-standard-paygo", "azure-cot-premium-paygo", "azure-cot-premium-byol",
"azure-cot-explore-paygo", "azure-ha-cot-standard-paygo", "azure-ha-cot-premium-paygo", "azure-ha-cot-premium-byol",
"capacity-paygo", "ha-capacity-paygo"}
AzureLicenseTypes is the Azure License types
var GCPLicenseTypes = []string{"gcp-cot-standard-paygo", "gcp-cot-explore-paygo", "gcp-cot-premium-paygo",
"gcp-cot-premium-byol", "gcp-ha-cot-standard-paygo", "gcp-ha-cot-premium-paygo", "gcp-ha-cot-explore-paygo",
"gcp-ha-cot-premium-byol", "capacity-paygo", "ha-capacity-paygo"}
GCPLicenseTypes is the GCP License types
Functions ¶
func Provider ¶
func Provider() terraform.ResourceProvider
Provider is the main method for NetApp CloudManager Terraform provider
Types ¶
type AWSInstanceMetadata ¶
type AWSInstanceMetadata struct { HTTPEndpoint *string HTTPPutResponseHopLimit *int64 HTTPTokens *string }
AWSInstanceMetadata describes the metadata options for the ec2 instance
type Client ¶
type Client struct { CloudManagerHost string AuthHost string SaAuthHost string SaSecretKey string SaClientID string CVOHostName string HostType string MaxConcurrentRequests int UserData string BaseURL string RefreshToken string Project string CloudManagerDomain string Audience string Auth0Client string ClientID string AccountID string IsSaas bool Token string AMIFilter string AWSAccount string AzureEnvironmentForOCCM string GCPDeploymentManager string GCPCompute string GCPImageProject string GCPImageFamily string GCPDeploymentTemplate string GCPServiceAccountKey string CVSHostName string Retries int Simulator bool AWSProfile string AWSProfileFilePath string AzureAuthMethods []string // contains filtered or unexported fields }
A Client to interact with the CVO/AWS/GCP/ANF/OCCM API
func (*Client) AzureAuthorize ¶
func (c *Client) AzureAuthorize() (autorest.Authorizer, error)
AzureAuthorize - Azure authorization using env or cli or both
func (*Client) CallAMIGet ¶
CallAMIGet can be used to make a request to get AWS AMI
func (*Client) CallAPIMethod ¶
func (c *Client) CallAPIMethod(method string, baseURL string, params map[string]interface{}, token string, hostType string, clientID string) (int, []byte, string, error)
CallAPIMethod can be used to make a request to any CVO/OCCM API method, receiving results as byte
func (*Client) CallAWSDescribeInstanceAttribute ¶
CallAWSDescribeInstanceAttribute returns disableAPITermination.
func (*Client) CallAWSGetReservationsForRegion ¶
CallAWSGetReservationsForRegion gets reservations for a region.
func (*Client) CallAWSInstanceCreate ¶
CallAWSInstanceCreate can be used to make a request to create AWS Instance
func (*Client) CallAWSInstanceGet ¶
CallAWSInstanceGet can be used to make a request to get AWS Instance
func (*Client) CallAWSInstanceTerminate ¶
CallAWSInstanceTerminate can be used to make a request to terminate AWS Instance
func (*Client) CallAWSInstanceUpdate ¶
CallAWSInstanceUpdate updates the instance metadata
func (*Client) CallAWSRegionGet ¶
CallAWSRegionGet describe all regions.
func (*Client) CallAWSTagCreate ¶
CallAWSTagCreate creates tag
func (*Client) CallAWSTagDelete ¶
CallAWSTagDelete deletes tag
func (*Client) CallDeleteAzureVM ¶
CallDeleteAzureVM can be used to make a request to delete Azure VM
func (*Client) CallDeployAzureVM ¶
CallDeployAzureVM can be used to make a request to deploy Azure VM
func (*Client) CallGetAzureVM ¶
CallGetAzureVM can be used to make a request to get Azure VM
func (*Client) CallVNetGet ¶
CallVNetGet can be used to make a request to get Azure virtual network
func (*Client) CallVNetGetCidr ¶
func (c *Client) CallVNetGetCidr(subscriptionID string, resourceGroup string, vnet string) (string, error)
CallVNetGetCidr can be used to make a request to get Azure virtual network
func (*Client) CallVPCGet ¶
CallVPCGet can be used to make a request to get AWS AMI
func (*Client) GetRefreshToken ¶
GetRefreshToken returns the API version that will be used for CVO/OCCM API requests
func (*Client) GetServiceCredential ¶
GetServiceCredential returns the service account secret key and secret client id that will be used for CVO/OCCM API requests
func (*Client) GetSimulator ¶
GetSimulator returns if it is set running on simulator
func (*Client) SetRefreshToken ¶
SetRefreshToken for the client to use for requests to the CVO/OCCM API
func (*Client) SetServiceCredential ¶
SetServiceCredential for the client to use for requests to the CVO/OCCM API
func (*Client) SetSimulator ¶
SetSimulator for the client to use for tests on simulator
type ExportPolicyInfo ¶
type ExportPolicyInfo struct { Name string `structs:"name,omitempty"` PolicyType string `structs:"policyType,omitempty"` Ips []string `structs:"ips,omitempty"` NfsVersion []string `structs:"nfsVersion,omitempty"` Rules []ExportPolicyRule `structs:"rules,omitempty"` }
ExportPolicyInfo describes the export policy section.
type ExportPolicyInfoResponse ¶
type ExportPolicyInfoResponse struct { Name string `json:"name"` PolicyType string `json:"policyType"` Ips []string `json:"ips"` NfsVersion []string `json:"nfsVersion"` Rules []ExportPolicyRule `json:"rules"` }
ExportPolicyInfoResponse describes the export policy section in API response.
type ExportPolicyRule ¶
type ExportPolicyRule struct { // Protocols []string `structs:"protocols"` // Clients []string `structs:"clients"` // RoRule []string `structs:"ro_rule"` // RwRule []string `structs:"rw_rule"` Superuser bool `structs:"superuser"` Index int32 `structs:"index,omitempty"` RuleAccessControl string `structs:"ruleAccessControl"` Ips []string `structs:"ips"` NfsVersion []string `structs:"nfsVersion,omitempty"` }
ExportPolicyRule describes the export policy rule section.
type OCCMMGCPResult ¶
type OCCMMGCPResult struct {
Name string `json:"name"`
}
OCCMMGCPResult the response name of a occm
Source Files ¶
- aggregate.go
- anf.go
- aws_fsx.go
- cbs.go
- cifs.go
- client.go
- config.go
- cvo_aws.go
- cvo_azure.go
- cvo_gcp.go
- cvo_onprem.go
- data_source_netapp_cloudmanager_aws_fsx.go
- data_source_netapp_cloudmanager_cifs_server.go
- data_source_netapp_cloudmanager_cvo_aws.go
- data_source_netapp_cloudmanager_nss_account.go
- data_source_netapp_cloudmanager_volume.go
- gcp_volume.go
- helper.go
- nss_account.go
- occm_aws.go
- occm_azure.go
- occm_azure_json.go
- occm_gcp.go
- provider.go
- resource_netapp_cloudmanager_aggregate.go
- resource_netapp_cloudmanager_anf_volume.go
- resource_netapp_cloudmanager_aws_fsx.go
- resource_netapp_cloudmanager_aws_fsx_volume.go
- resource_netapp_cloudmanager_cbs.go
- resource_netapp_cloudmanager_cifs_server.go
- resource_netapp_cloudmanager_connector_aws.go
- resource_netapp_cloudmanager_connector_azure.go
- resource_netapp_cloudmanager_connector_gcp.go
- resource_netapp_cloudmanager_cvo_aws.go
- resource_netapp_cloudmanager_cvo_azure.go
- resource_netapp_cloudmanager_cvo_gcp.go
- resource_netapp_cloudmanager_cvo_onprem.go
- resource_netapp_cloudmanager_cvs_gcp_volume.go
- resource_netapp_cloudmanager_nss_account.go
- resource_netapp_cloudmanager_snapmirror.go
- resource_netapp_cloudmanager_volume.go
- snapmirror.go
- volume.go