Skip to content

Commit

Permalink
Merge pull request #178 from NetApp/integration/main
Browse files Browse the repository at this point in the history
Integration/main
  • Loading branch information
wenjun666 authored Oct 5, 2023
2 parents c4723b9 + 2cadf88 commit b1d23ba
Show file tree
Hide file tree
Showing 7 changed files with 57 additions and 10 deletions.
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
## 23.8.2
ENHANCEMENTS:
* support dev environment.
* resources/cvo: update the documentation on the `ontap_version` naming convention and the way to find the available upgrade versions on `upgrade_ontap_version`.

## 23.8.1
NEW FEATURES:
* resource/cvo_gcp: support LDM/flashCache on both single and HA.
Expand Down
2 changes: 1 addition & 1 deletion cloudmanager/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -276,7 +276,7 @@ func (c *Client) CallDeployAzureVM(occmDetails createOCCMDetails) (string, error
"value": occmDetails.StorageAccount,
}

if c.AzureEnvironmentForOCCM == "stage" {
if c.AzureEnvironmentForOCCM == "stage" || c.AzureEnvironmentForOCCM == "dev" {
(*params)["environment"] = map[string]string{
"value": c.AzureEnvironmentForOCCM,
}
Expand Down
19 changes: 18 additions & 1 deletion cloudmanager/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,25 @@ func (c *configStruct) clientFun() (*Client, error) {
AzureEnvironmentForOCCM: "stage",
CVSHostName: "https://staging.api.bluexp.netapp.com/cloud-volumes/cvs",
}
} else if c.Environment == "dev" {
log.Print("Dev Environment")
client = &Client{
CloudManagerHost: "https://dev.api.bluexp.netapp.com",
AuthHost: "https://staging.api.bluexp.netapp.com/auth/oauth/token",
SaAuthHost: "https://staging.api.bluexp.netapp.com/auth/oauth/token",
Audience: "https://api.cloud.netapp.com",
Auth0Client: "O6AHa7kedZfzHaxN80dnrIcuPBGEUvEv",
AMIFilter: "Setup-As-Service-AMI-*",
AWSAccount: "282316784512",
GCPDeploymentManager: "https://www.googleapis.com",
GCPCompute: "https://compute.googleapis.com",
GCPImageProject: "tlv-automation",
GCPImageFamily: "occm-automation",
AzureEnvironmentForOCCM: "stage",
CVSHostName: "https://dev.api.bluexp.netapp.com/cloud-volumes/cvs",
}
} else {
return &Client{}, fmt.Errorf("expected environment to be one of [prod stage]: %s", c.Environment)
return &Client{}, fmt.Errorf("expected environment to be one of [prod stage dev]: %s", c.Environment)
}

if c.SaSecretKey != "" && c.SaClientID != "" {
Expand Down
4 changes: 2 additions & 2 deletions cloudmanager/occm_azure_json.go
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ func (c *Client) callTemplate() string {
"publicIpAddressType": "Dynamic",
"publicIpAddressSku": "Basic",
"msiExtensionName": "ManagedIdentityExtensionForLinux",
"occmOffer": "[if(equals(parameters('environment'), 'stage'), 'netapp-oncommand-cloud-manager-staging-preview', 'netapp-oncommand-cloud-manager')]"
"occmOffer": "[if(or(equals(parameters('environment'), 'stage'), equals(parameters('environment'), 'dev')), 'netapp-oncommand-cloud-manager-staging-preview', 'netapp-oncommand-cloud-manager')]"
},
"resources": [
{
Expand Down Expand Up @@ -279,7 +279,7 @@ func (c *Client) callTemplateDisablePublicIP() string {
"publicIpAddressType": "Dynamic",
"publicIpAddressSku": "Basic",
"msiExtensionName": "ManagedIdentityExtensionForLinux",
"occmOffer": "[if(equals(parameters('environment'), 'stage'), 'netapp-oncommand-cloud-manager-staging-preview', 'netapp-oncommand-cloud-manager')]"
"occmOffer": "[if(or(equals(parameters('environment'), 'stage'), equals(parameters('environment'), 'dev')), 'netapp-oncommand-cloud-manager-staging-preview', 'netapp-oncommand-cloud-manager')]"
},
"resources": [
{
Expand Down
12 changes: 10 additions & 2 deletions website/docs/r/cvo_aws.html.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,15 @@ The following arguments are supported:
* `iops` - (Optional) Provisioned IOPS. Required only when 'ebs_volume_type' is 'io1' or 'gp3'.
* `throughput` - (Optional) Required only when 'ebs_volume_type' is 'gp3'.
* `cluster_key_pair_name` - (Optional) Use for SSH authentication key pair method.
* `ontap_version` - (Optional) The required ONTAP version. Ignored if 'use_latest_version' is set to true. The default is to use the latest version.
* `ontap_version` - (Optional) The required ONTAP version. Ignored if 'use_latest_version' is set to true. The default is to use the latest version. The naming convention:

|Release|Naming convention|Example|
|-------|-----------------|-------|
|Patch Single | `ONTAP-${version}` | ONTAP-9.13.1P1|
|Patch HA | `ONTAP-${version}.ha` | ONTAP-9.13.1P1.ha|
|Regular Single | `ONTAP-${version}.T1` | ONTAP-9.14.0.T1|
|Regular HA | `ONTAP-${version}.T1.ha` | ONTAP-9.14.0.T1.ha|

* `use_latest_version` - (Optional) Indicates whether to use the latest available ONTAP version. The default is 'true'.
* `license_type` - (Optional) The type of license to use. For single node: (by Capacity): ['capacity-paygo'], (by Node paygo): ['cot-explore-paygo','cot-standard-paygo', 'cot-premium-paygo'], (by Node byol): ['cot-premium-byol']. For HA: (by Capacity): ['ha-capacity-paygo'], (by Node paygo): ['ha-cot-explore-paygo','ha-cot-standard-paygo','ha-cot-premium-paygo'], (by Node byol): 'ha-cot-premium-byol']. The default is 'capacity-paygo' for single node, and 'ha-capacity-paygo' for HA.
* `capacity_package_name` - (Optional) The capacity package name: ['Essential', 'Professional', 'Freemium']. Default is 'Essential'.
Expand Down Expand Up @@ -150,7 +158,7 @@ The following arguments are supported:
* `data_floating_ip` - (Optional) For HA FloatingIP, the data floating IP address.
* `svm_floating_ip` - (Optional) For HA FloatingIP, the SVM management floating IP address.
* `route_table_ids` - (Optional) For HA FloatingIP, the list of route table IDs that will be updated with the floating IPs.
* `upgrade_ontap_version` - (Optional) Indicates whether to upgrade ontap image with `ontap_version`. To upgrade ontap image, `ontap_version` cannot be 'latest' and `use_latest_version` needs to be false.
* `upgrade_ontap_version` - (Optional) Indicates whether to upgrade ontap image with `ontap_version`. To upgrade ontap image, `ontap_version` cannot be 'latest' and `use_latest_version` needs to be false. The available versions can be found in BlueXP UI. Click the CVO -> click **New Version Available** under **Notifications** -> the latest available version will be shown. The list of available versions can be found in **Select older versions**. Update the `ontap_version` by follow the naming conversion.
* `mediator_security_group_id` - (Optional) For HA only, mediator security group id.
* `assume_role_arn` - (Optional) For HA only, Amazon Resource Name ARN of an AWS Identity and Access Managent IAM role that has created in the VPC owner account. For example, "arn:aws:iam::61239912384567:role/mediator_role_assume_fromdev"
* `retries` - (Optional) The number of attempts to wait for the completion of creating the CVO with 60 seconds apart for each attempt. For HA, this value is incremented by 30. The default is '60'.
Expand Down
13 changes: 11 additions & 2 deletions website/docs/r/cvo_azure.html.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,16 @@ The following arguments are supported:
* `cidr` - (Optional) The CIDR of the VNET. If not provided, resource needs az login to authorize and fetch the cidr details from Azure.
* `disk_size` - (Optional) Azure volume size for the first data aggregate. For GB, the unit can be: [100 or 500]. For TB, the unit can be: [1,2,4,8,16]. The default is '1' .
* `disk_size_unit` - (Optional) ['GB' or 'TB']. The default is 'TB'.
* `ontap_version` - (Optional) The required ONTAP version. Ignored if 'use_latest_version' is set to true. The default is to use the latest version.
* `ontap_version` - (Optional) The required ONTAP version. Ignored if `use_latest_version` is set to true. The default is to use the latest version. The naming convention:
The naming convention:

|Release|Naming convention|Example|
|-------|-----------------|-------|
|Patch Single | `ONTAP-${version}.azure` | ONTAP-9.13.1P1.azure|
|Patch HA | `ONTAP-${version}.azureha` | ONTAP-9.13.1P1.azureha|
|Regular Single | `ONTAP-${version}.T1.azure` | ONTAP-9.14.0.T1.azure|
|Regular HA | `ONTAP-${version}.T1.azureha` | ONTAP-9.14.0.T1.azureha|

* `use_latest_version` - (Optional) Indicates whether to use the latest available ONTAP version. The default is 'true'.
* `license_type` - (Optional) The type of license to be use. For single node: (by Capacity): ['capacity-paygo'], (by Node paygo): ['azure-cot-explore-paygo', 'azure-cot-standard-paygo', 'azure-cot-premium-paygo'], (by Node byol): ['azure-cot-premium-byol']. For HA: (by Capacity): ['ha-capacity-paygo'], (by Node paygo): ['azure-ha-cot-standard-paygo', 'azure-ha-cot-premium-paygo'], (by Node byol): ['azure-ha-cot-premium-byol']. The default is 'capacity-paygo' for single node, and 'ha-capacity-paygo'for HA.
* `capacity_package_name` - (Optional) The capacity package name: ['Essential', 'Professional', 'Freemium', 'Edge', 'Optimized']. Default is 'Essential'. 'Edge' and 'Optimized' need ontap version 9.11.0 or above.
Expand All @@ -158,7 +167,7 @@ The following arguments are supported:
* `availability_zone_node1` - (Optional) For HA, the availability zone for the first node.
* `availability_zone_node2` - (Optional) For HA, the availability zone for the second node.
* `ha_enable_https` - (Optional) For HA, enable the HTTPS connection from CVO to storage accounts. This can impact write performance. The default is false.
* `upgrade_ontap_version` - (Optional) Indicates whether to upgrade ontap image with `ontap_version`. To upgrade ontap image, `ontap_version` cannot be 'latest' and `use_latest_version` needs to be false.
* `upgrade_ontap_version` - (Optional) Indicates whether to upgrade ontap image with `ontap_version`. To upgrade ontap image, `ontap_version` cannot be 'latest' and `use_latest_version` needs to be false. The available versions can be found in BlueXP UI. Click the CVO -> click **New Version Available** under **Notifications** -> the latest available version will be shown. The list of available versions can be found in **Select older versions**. Update the `ontap_version` by follow the naming conversion.
* `retries` - (Optional) The number of attempts to wait for the completion of creating the CVO with 60 seconds apart for each attempt. For HA, this value is incremented by 30. The default is '60'.
* `worm_retention_period_length` - (Optional) WORM retention period length. Once specified retention period, the WORM is enabled. When WORM storage is activated, data tiering to object storage can’t be enabled.
* `worm_retention_period_unit` - (Optional) WORM retention period unit: ['years','months','days','hours','minutes','seconds'].
Expand Down
12 changes: 10 additions & 2 deletions website/docs/r/cvo_gcp.html.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,15 @@ The following arguments are supported:
* `vpc_id` - (Optional) The name of the VPC.
* `gcp_volume_size` - (Optional) The GCP volume size for the first data aggregate. For GB, the unit can be: [100 or 500]. For TB, the unit can be: [1,2,4,8]. The default is '1' .
* `gcp_volume_size_unit` - (Optional) ['GB' or 'TB']. The default is 'TB'.
* `ontap_version` - (Optional) The required ONTAP version. Ignored if 'use_latest_version' is set to true. The default is to use the latest version.
* `ontap_version` - (Optional) The required ONTAP version. Ignored if `use_latest_version` is set to true. The default is to use the latest version. The naming convention:

|Release|Naming convention|Example|
|-------|-----------------|-------|
|Patch Single | `ONTAP-${version}.gcp` | ONTAP-9.13.1P1.gcp|
|Patch HA | `ONTAP-${version}.gcpha` | ONTAP-9.13.1P1.gcpha|
|Regular Single | `ONTAP-${version}.T1.gcp` | ONTAP-9.10.1RC1.T1.gcp|
|Regular HA | `ONTAP-${version}.T1.gcpha` | ONTAP-9.13.0.T1.gcpha|

* `use_latest_version` - (Optional) Indicates whether to use the latest available ONTAP version. The default is 'true'.
* `license_type` - (Optional) The type of license to use. For single node: (by Capacity): ['capacity-paygo'], (by Node paygo): ['gcp-cot-explore-paygo', 'gcp-cot-standard-paygo', 'gcp-cot-premium-paygo'], (by Node byol): ['gcp-cot-premium-byol'], For HA: (by Capacity): ['ha-capacity-paygo'], (by Node paygo): ['gcp-ha-cot-explore-paygo', 'gcp-ha-cot-standard-paygo', 'gcp-ha-cot-premium-paygo'], (by Node byol): ['gcp-ha-cot-premium-byol']. The default is 'capacity-paygo' for single node, and 'ha-capacity-paygo'for HA.
* `capacity_package_name` - (Optional) The capacity package name: ['Essential', 'Professional', 'Freemium', 'Edge', 'Optimized']. Default is 'Essential'. 'Edge' and 'Optimized' need ontap version 9.11.1 or above.
Expand Down Expand Up @@ -162,7 +170,7 @@ The following arguments are supported:
* `vpc1_firewall_rule_tag_name` - (Optional) Firewall rule tag name for vpc2.
* `vpc2_firewall_rule_tag_name` - (Optional) Firewall rule tag name for vpc3.
* `vpc3_firewall_rule_tag_name` - (Optional) Firewall rule tag name for vpc4.
* `upgrade_ontap_version` - (Optional) Indicates whether to upgrade ontap image with `ontap_version`. To upgrade ontap image, `ontap_version` cannot be 'latest' and `use_latest_version` needs to be false.
* `upgrade_ontap_version` - (Optional) Indicates whether to upgrade ontap image with `ontap_version`. To upgrade ontap image, `ontap_version` cannot be 'latest' and `use_latest_version` needs to be false. The available versions can be found in BlueXP UI. Click the CVO -> click **New Version Available** under **Notifications** -> the latest available version will be shown. The list of available versions can be found in **Select older versions**. Update the `ontap_version` by follow the naming conversion.
* `retries` - (Optional) The number of attempts to wait for the completion of creating the CVO with 60 seconds apart for each attempt. For HA, this value is incremented by 30. The default is '60'.
* `worm_retention_period_length` - (Optional) WORM retention period length. Once specified retention period, the WORM is enabled. When WORM storage is activated, data tiering to object storage can’t be enabled.
* `worm_retention_period_unit` - (Optional) WORM retention period unit: ['years','months','days','hours','minutes','seconds'].
Expand Down

0 comments on commit b1d23ba

Please sign in to comment.