pulumi-alicloud 3.65.0a1730524658__py3-none-any.whl → 3.65.1__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of pulumi-alicloud might be problematic. Click here for more details.

Files changed (55) hide show
  1. pulumi_alicloud/__init__.py +19 -0
  2. pulumi_alicloud/alb/load_balancer.py +1 -1
  3. pulumi_alicloud/arms/environment.py +7 -7
  4. pulumi_alicloud/arms/get_remote_writes.py +4 -4
  5. pulumi_alicloud/arms/prometheus_alert_rule.py +58 -0
  6. pulumi_alicloud/arms/remote_write.py +2 -2
  7. pulumi_alicloud/cen/transit_router_route_table_association.py +72 -68
  8. pulumi_alicloud/cen/transit_router_vbr_attachment.py +96 -74
  9. pulumi_alicloud/cloudstoragegateway/gateway.py +134 -58
  10. pulumi_alicloud/cms/hybrid_monitor_fc_task.py +28 -26
  11. pulumi_alicloud/cr/chain.py +22 -14
  12. pulumi_alicloud/cr/chart_repository.py +14 -6
  13. pulumi_alicloud/cr/repo.py +8 -8
  14. pulumi_alicloud/cr/vpc_endpoint_linked_vpc.py +14 -6
  15. pulumi_alicloud/cs/_inputs.py +6 -6
  16. pulumi_alicloud/cs/outputs.py +4 -4
  17. pulumi_alicloud/databasefilesystem/instance_attachment.py +59 -63
  18. pulumi_alicloud/databasefilesystem/snapshot.py +53 -109
  19. pulumi_alicloud/ecs/instance.py +7 -7
  20. pulumi_alicloud/ess/scaling_configuration.py +8 -8
  21. pulumi_alicloud/ess/scaling_group.py +54 -7
  22. pulumi_alicloud/fc/_inputs.py +3 -3
  23. pulumi_alicloud/fc/outputs.py +2 -2
  24. pulumi_alicloud/fc/trigger.py +202 -138
  25. pulumi_alicloud/ga/custom_routing_endpoint_traffic_policy.py +48 -44
  26. pulumi_alicloud/governance/_inputs.py +54 -0
  27. pulumi_alicloud/governance/account.py +49 -14
  28. pulumi_alicloud/governance/outputs.py +51 -0
  29. pulumi_alicloud/gpdb/instance.py +196 -15
  30. pulumi_alicloud/kms/get_secrets.py +5 -5
  31. pulumi_alicloud/kms/instance.py +28 -0
  32. pulumi_alicloud/kms/outputs.py +18 -18
  33. pulumi_alicloud/mse/__init__.py +2 -0
  34. pulumi_alicloud/mse/get_nacos_configs.py +394 -0
  35. pulumi_alicloud/mse/nacos_config.py +762 -0
  36. pulumi_alicloud/mse/outputs.py +129 -0
  37. pulumi_alicloud/nas/data_flow.py +6 -6
  38. pulumi_alicloud/nas/fileset.py +6 -6
  39. pulumi_alicloud/nas/lifecycle_policy.py +6 -6
  40. pulumi_alicloud/nas/recycle_bin.py +6 -6
  41. pulumi_alicloud/nas/snapshot.py +6 -6
  42. pulumi_alicloud/ocean/base_instance.py +2 -2
  43. pulumi_alicloud/pai/__init__.py +8 -0
  44. pulumi_alicloud/pai/workspace_workspace.py +447 -0
  45. pulumi_alicloud/polardb/cluster.py +14 -14
  46. pulumi_alicloud/pulumi-plugin.json +1 -1
  47. pulumi_alicloud/redis/tair_instance.py +1102 -71
  48. pulumi_alicloud/threatdetection/honeypot_preset.py +2 -0
  49. pulumi_alicloud/vpc/subnet.py +59 -27
  50. pulumi_alicloud/vpc/switch.py +104 -87
  51. pulumi_alicloud/vpn/gateway_vco_route.py +28 -8
  52. {pulumi_alicloud-3.65.0a1730524658.dist-info → pulumi_alicloud-3.65.1.dist-info}/METADATA +1 -1
  53. {pulumi_alicloud-3.65.0a1730524658.dist-info → pulumi_alicloud-3.65.1.dist-info}/RECORD +55 -51
  54. {pulumi_alicloud-3.65.0a1730524658.dist-info → pulumi_alicloud-3.65.1.dist-info}/WHEEL +1 -1
  55. {pulumi_alicloud-3.65.0a1730524658.dist-info → pulumi_alicloud-3.65.1.dist-info}/top_level.txt +0 -0
@@ -33,18 +33,18 @@ class GatewayArgs:
33
33
  vswitch_id: Optional[pulumi.Input[str]] = None):
34
34
  """
35
35
  The set of arguments for constructing a Gateway resource.
36
- :param pulumi.Input[str] gateway_name: The name of the gateway.
36
+ :param pulumi.Input[str] gateway_name: The name of the gateway. The name must be `1` to `60` characters in length and can contain letters, digits, periods (.), underscores (_), and hyphens (-). It must start with a letter.
37
37
  :param pulumi.Input[str] location: The location of the gateway. Valid values: `Cloud`, `On_Premise`.
38
38
  :param pulumi.Input[str] storage_bundle_id: The ID of the gateway cluster.
39
39
  :param pulumi.Input[str] type: The type of the gateway. Valid values: `File`, `Iscsi`.
40
40
  :param pulumi.Input[str] description: The description of the gateway.
41
- :param pulumi.Input[str] gateway_class: The specification of the gateway. Valid values: `Basic`, `Standard`,`Enhanced`,`Advanced`.
42
- :param pulumi.Input[str] payment_type: The Payment type of gateway. Valid values: `PayAsYouGo`.
43
- :param pulumi.Input[int] public_network_bandwidth: The public network bandwidth of gateway. Default value: `5`. Valid values: `5` to `200`.
44
- :param pulumi.Input[str] reason_detail: The reason detail of gateway.
45
- :param pulumi.Input[str] reason_type: The reason type when user deletes the gateway.
46
- :param pulumi.Input[bool] release_after_expiration: Whether to release the gateway due to expiration.
47
- :param pulumi.Input[str] vswitch_id: The ID of the vSwitch.
41
+ :param pulumi.Input[str] gateway_class: The specification of the gateway. Valid values: `Basic`, `Standard`, `Enhanced`, `Advanced`. **NOTE:** If `location` is set to `Cloud`, `gateway_class` is required. Otherwise, `gateway_class` will be ignored. If `payment_type` is set to `Subscription`, `gateway_class` cannot be modified.
42
+ :param pulumi.Input[str] payment_type: The Payment type of gateway. Valid values: `PayAsYouGo`, `Subscription`. **NOTE:** From version 1.233.0, `payment_type` can be set to `Subscription`.
43
+ :param pulumi.Input[int] public_network_bandwidth: The public bandwidth of the gateway. Default value: `5`. Valid values: `5` to `200`. **NOTE:** `public_network_bandwidth` is only valid when `location` is `Cloud`. If `payment_type` is set to `Subscription`, `public_network_bandwidth` cannot be modified.
44
+ :param pulumi.Input[str] reason_detail: The detailed reason why you want to delete the gateway.
45
+ :param pulumi.Input[str] reason_type: The type of the reason why you want to delete the gateway.
46
+ :param pulumi.Input[bool] release_after_expiration: Specifies whether to release the gateway after the subscription expires. Valid values:
47
+ :param pulumi.Input[str] vswitch_id: The ID of the VSwitch. **NOTE:** If `location` is set to `Cloud`, `vswitch_id` is required. Otherwise, `vswitch_id` will be ignored.
48
48
  """
49
49
  pulumi.set(__self__, "gateway_name", gateway_name)
50
50
  pulumi.set(__self__, "location", location)
@@ -71,7 +71,7 @@ class GatewayArgs:
71
71
  @pulumi.getter(name="gatewayName")
72
72
  def gateway_name(self) -> pulumi.Input[str]:
73
73
  """
74
- The name of the gateway.
74
+ The name of the gateway. The name must be `1` to `60` characters in length and can contain letters, digits, periods (.), underscores (_), and hyphens (-). It must start with a letter.
75
75
  """
76
76
  return pulumi.get(self, "gateway_name")
77
77
 
@@ -131,7 +131,7 @@ class GatewayArgs:
131
131
  @pulumi.getter(name="gatewayClass")
132
132
  def gateway_class(self) -> Optional[pulumi.Input[str]]:
133
133
  """
134
- The specification of the gateway. Valid values: `Basic`, `Standard`,`Enhanced`,`Advanced`.
134
+ The specification of the gateway. Valid values: `Basic`, `Standard`, `Enhanced`, `Advanced`. **NOTE:** If `location` is set to `Cloud`, `gateway_class` is required. Otherwise, `gateway_class` will be ignored. If `payment_type` is set to `Subscription`, `gateway_class` cannot be modified.
135
135
  """
136
136
  return pulumi.get(self, "gateway_class")
137
137
 
@@ -143,7 +143,7 @@ class GatewayArgs:
143
143
  @pulumi.getter(name="paymentType")
144
144
  def payment_type(self) -> Optional[pulumi.Input[str]]:
145
145
  """
146
- The Payment type of gateway. Valid values: `PayAsYouGo`.
146
+ The Payment type of gateway. Valid values: `PayAsYouGo`, `Subscription`. **NOTE:** From version 1.233.0, `payment_type` can be set to `Subscription`.
147
147
  """
148
148
  return pulumi.get(self, "payment_type")
149
149
 
@@ -155,7 +155,7 @@ class GatewayArgs:
155
155
  @pulumi.getter(name="publicNetworkBandwidth")
156
156
  def public_network_bandwidth(self) -> Optional[pulumi.Input[int]]:
157
157
  """
158
- The public network bandwidth of gateway. Default value: `5`. Valid values: `5` to `200`.
158
+ The public bandwidth of the gateway. Default value: `5`. Valid values: `5` to `200`. **NOTE:** `public_network_bandwidth` is only valid when `location` is `Cloud`. If `payment_type` is set to `Subscription`, `public_network_bandwidth` cannot be modified.
159
159
  """
160
160
  return pulumi.get(self, "public_network_bandwidth")
161
161
 
@@ -167,7 +167,7 @@ class GatewayArgs:
167
167
  @pulumi.getter(name="reasonDetail")
168
168
  def reason_detail(self) -> Optional[pulumi.Input[str]]:
169
169
  """
170
- The reason detail of gateway.
170
+ The detailed reason why you want to delete the gateway.
171
171
  """
172
172
  return pulumi.get(self, "reason_detail")
173
173
 
@@ -179,7 +179,7 @@ class GatewayArgs:
179
179
  @pulumi.getter(name="reasonType")
180
180
  def reason_type(self) -> Optional[pulumi.Input[str]]:
181
181
  """
182
- The reason type when user deletes the gateway.
182
+ The type of the reason why you want to delete the gateway.
183
183
  """
184
184
  return pulumi.get(self, "reason_type")
185
185
 
@@ -191,7 +191,7 @@ class GatewayArgs:
191
191
  @pulumi.getter(name="releaseAfterExpiration")
192
192
  def release_after_expiration(self) -> Optional[pulumi.Input[bool]]:
193
193
  """
194
- Whether to release the gateway due to expiration.
194
+ Specifies whether to release the gateway after the subscription expires. Valid values:
195
195
  """
196
196
  return pulumi.get(self, "release_after_expiration")
197
197
 
@@ -203,7 +203,7 @@ class GatewayArgs:
203
203
  @pulumi.getter(name="vswitchId")
204
204
  def vswitch_id(self) -> Optional[pulumi.Input[str]]:
205
205
  """
206
- The ID of the vSwitch.
206
+ The ID of the VSwitch. **NOTE:** If `location` is set to `Cloud`, `vswitch_id` is required. Otherwise, `vswitch_id` will be ignored.
207
207
  """
208
208
  return pulumi.get(self, "vswitch_id")
209
209
 
@@ -231,18 +231,18 @@ class _GatewayState:
231
231
  """
232
232
  Input properties used for looking up and filtering Gateway resources.
233
233
  :param pulumi.Input[str] description: The description of the gateway.
234
- :param pulumi.Input[str] gateway_class: The specification of the gateway. Valid values: `Basic`, `Standard`,`Enhanced`,`Advanced`.
235
- :param pulumi.Input[str] gateway_name: The name of the gateway.
234
+ :param pulumi.Input[str] gateway_class: The specification of the gateway. Valid values: `Basic`, `Standard`, `Enhanced`, `Advanced`. **NOTE:** If `location` is set to `Cloud`, `gateway_class` is required. Otherwise, `gateway_class` will be ignored. If `payment_type` is set to `Subscription`, `gateway_class` cannot be modified.
235
+ :param pulumi.Input[str] gateway_name: The name of the gateway. The name must be `1` to `60` characters in length and can contain letters, digits, periods (.), underscores (_), and hyphens (-). It must start with a letter.
236
236
  :param pulumi.Input[str] location: The location of the gateway. Valid values: `Cloud`, `On_Premise`.
237
- :param pulumi.Input[str] payment_type: The Payment type of gateway. Valid values: `PayAsYouGo`.
238
- :param pulumi.Input[int] public_network_bandwidth: The public network bandwidth of gateway. Default value: `5`. Valid values: `5` to `200`.
239
- :param pulumi.Input[str] reason_detail: The reason detail of gateway.
240
- :param pulumi.Input[str] reason_type: The reason type when user deletes the gateway.
241
- :param pulumi.Input[bool] release_after_expiration: Whether to release the gateway due to expiration.
237
+ :param pulumi.Input[str] payment_type: The Payment type of gateway. Valid values: `PayAsYouGo`, `Subscription`. **NOTE:** From version 1.233.0, `payment_type` can be set to `Subscription`.
238
+ :param pulumi.Input[int] public_network_bandwidth: The public bandwidth of the gateway. Default value: `5`. Valid values: `5` to `200`. **NOTE:** `public_network_bandwidth` is only valid when `location` is `Cloud`. If `payment_type` is set to `Subscription`, `public_network_bandwidth` cannot be modified.
239
+ :param pulumi.Input[str] reason_detail: The detailed reason why you want to delete the gateway.
240
+ :param pulumi.Input[str] reason_type: The type of the reason why you want to delete the gateway.
241
+ :param pulumi.Input[bool] release_after_expiration: Specifies whether to release the gateway after the subscription expires. Valid values:
242
242
  :param pulumi.Input[str] status: The status of the Gateway.
243
243
  :param pulumi.Input[str] storage_bundle_id: The ID of the gateway cluster.
244
244
  :param pulumi.Input[str] type: The type of the gateway. Valid values: `File`, `Iscsi`.
245
- :param pulumi.Input[str] vswitch_id: The ID of the vSwitch.
245
+ :param pulumi.Input[str] vswitch_id: The ID of the VSwitch. **NOTE:** If `location` is set to `Cloud`, `vswitch_id` is required. Otherwise, `vswitch_id` will be ignored.
246
246
  """
247
247
  if description is not None:
248
248
  pulumi.set(__self__, "description", description)
@@ -287,7 +287,7 @@ class _GatewayState:
287
287
  @pulumi.getter(name="gatewayClass")
288
288
  def gateway_class(self) -> Optional[pulumi.Input[str]]:
289
289
  """
290
- The specification of the gateway. Valid values: `Basic`, `Standard`,`Enhanced`,`Advanced`.
290
+ The specification of the gateway. Valid values: `Basic`, `Standard`, `Enhanced`, `Advanced`. **NOTE:** If `location` is set to `Cloud`, `gateway_class` is required. Otherwise, `gateway_class` will be ignored. If `payment_type` is set to `Subscription`, `gateway_class` cannot be modified.
291
291
  """
292
292
  return pulumi.get(self, "gateway_class")
293
293
 
@@ -299,7 +299,7 @@ class _GatewayState:
299
299
  @pulumi.getter(name="gatewayName")
300
300
  def gateway_name(self) -> Optional[pulumi.Input[str]]:
301
301
  """
302
- The name of the gateway.
302
+ The name of the gateway. The name must be `1` to `60` characters in length and can contain letters, digits, periods (.), underscores (_), and hyphens (-). It must start with a letter.
303
303
  """
304
304
  return pulumi.get(self, "gateway_name")
305
305
 
@@ -323,7 +323,7 @@ class _GatewayState:
323
323
  @pulumi.getter(name="paymentType")
324
324
  def payment_type(self) -> Optional[pulumi.Input[str]]:
325
325
  """
326
- The Payment type of gateway. Valid values: `PayAsYouGo`.
326
+ The Payment type of gateway. Valid values: `PayAsYouGo`, `Subscription`. **NOTE:** From version 1.233.0, `payment_type` can be set to `Subscription`.
327
327
  """
328
328
  return pulumi.get(self, "payment_type")
329
329
 
@@ -335,7 +335,7 @@ class _GatewayState:
335
335
  @pulumi.getter(name="publicNetworkBandwidth")
336
336
  def public_network_bandwidth(self) -> Optional[pulumi.Input[int]]:
337
337
  """
338
- The public network bandwidth of gateway. Default value: `5`. Valid values: `5` to `200`.
338
+ The public bandwidth of the gateway. Default value: `5`. Valid values: `5` to `200`. **NOTE:** `public_network_bandwidth` is only valid when `location` is `Cloud`. If `payment_type` is set to `Subscription`, `public_network_bandwidth` cannot be modified.
339
339
  """
340
340
  return pulumi.get(self, "public_network_bandwidth")
341
341
 
@@ -347,7 +347,7 @@ class _GatewayState:
347
347
  @pulumi.getter(name="reasonDetail")
348
348
  def reason_detail(self) -> Optional[pulumi.Input[str]]:
349
349
  """
350
- The reason detail of gateway.
350
+ The detailed reason why you want to delete the gateway.
351
351
  """
352
352
  return pulumi.get(self, "reason_detail")
353
353
 
@@ -359,7 +359,7 @@ class _GatewayState:
359
359
  @pulumi.getter(name="reasonType")
360
360
  def reason_type(self) -> Optional[pulumi.Input[str]]:
361
361
  """
362
- The reason type when user deletes the gateway.
362
+ The type of the reason why you want to delete the gateway.
363
363
  """
364
364
  return pulumi.get(self, "reason_type")
365
365
 
@@ -371,7 +371,7 @@ class _GatewayState:
371
371
  @pulumi.getter(name="releaseAfterExpiration")
372
372
  def release_after_expiration(self) -> Optional[pulumi.Input[bool]]:
373
373
  """
374
- Whether to release the gateway due to expiration.
374
+ Specifies whether to release the gateway after the subscription expires. Valid values:
375
375
  """
376
376
  return pulumi.get(self, "release_after_expiration")
377
377
 
@@ -419,7 +419,7 @@ class _GatewayState:
419
419
  @pulumi.getter(name="vswitchId")
420
420
  def vswitch_id(self) -> Optional[pulumi.Input[str]]:
421
421
  """
422
- The ID of the vSwitch.
422
+ The ID of the VSwitch. **NOTE:** If `location` is set to `Cloud`, `vswitch_id` is required. Otherwise, `vswitch_id` will be ignored.
423
423
  """
424
424
  return pulumi.get(self, "vswitch_id")
425
425
 
@@ -449,10 +449,48 @@ class Gateway(pulumi.CustomResource):
449
449
  """
450
450
  Provides a Cloud Storage Gateway Gateway resource.
451
451
 
452
- For information about Cloud Storage Gateway Gateway and how to use it, see [What is Gateway](https://www.alibabacloud.com/help/en/cloud-storage-gateway/latest/deploygateway).
452
+ For information about Cloud Storage Gateway Gateway and how to use it, see [What is Gateway](https://www.alibabacloud.com/help/en/csg/developer-reference/api-mnz46x).
453
453
 
454
454
  > **NOTE:** Available since v1.132.0.
455
455
 
456
+ ## Example Usage
457
+
458
+ Basic Usage
459
+
460
+ ```python
461
+ import pulumi
462
+ import pulumi_alicloud as alicloud
463
+ import pulumi_random as random
464
+
465
+ config = pulumi.Config()
466
+ name = config.get("name")
467
+ if name is None:
468
+ name = "terraform-example"
469
+ default = alicloud.get_zones()
470
+ default_integer = random.index.Integer("default",
471
+ min=10000,
472
+ max=99999)
473
+ default_storage_bundle = alicloud.cloudstoragegateway.StorageBundle("default", storage_bundle_name=f"{name}-{default_integer['result']}")
474
+ default_network = alicloud.vpc.Network("default",
475
+ vpc_name=f"{name}-{default_integer['result']}",
476
+ cidr_block="192.168.0.0/16")
477
+ default_switch = alicloud.vpc.Switch("default",
478
+ vswitch_name=f"{name}-{default_integer['result']}",
479
+ vpc_id=default_network.id,
480
+ cidr_block="192.168.192.0/24",
481
+ zone_id=default.zones[0].id)
482
+ default_gateway = alicloud.cloudstoragegateway.Gateway("default",
483
+ storage_bundle_id=default_storage_bundle.id,
484
+ type="File",
485
+ location="Cloud",
486
+ gateway_name=name,
487
+ gateway_class="Standard",
488
+ vswitch_id=default_switch.id,
489
+ public_network_bandwidth=50,
490
+ payment_type="PayAsYouGo",
491
+ description=name)
492
+ ```
493
+
456
494
  ## Import
457
495
 
458
496
  Cloud Storage Gateway Gateway can be imported using the id, e.g.
@@ -464,17 +502,17 @@ class Gateway(pulumi.CustomResource):
464
502
  :param str resource_name: The name of the resource.
465
503
  :param pulumi.ResourceOptions opts: Options for the resource.
466
504
  :param pulumi.Input[str] description: The description of the gateway.
467
- :param pulumi.Input[str] gateway_class: The specification of the gateway. Valid values: `Basic`, `Standard`,`Enhanced`,`Advanced`.
468
- :param pulumi.Input[str] gateway_name: The name of the gateway.
505
+ :param pulumi.Input[str] gateway_class: The specification of the gateway. Valid values: `Basic`, `Standard`, `Enhanced`, `Advanced`. **NOTE:** If `location` is set to `Cloud`, `gateway_class` is required. Otherwise, `gateway_class` will be ignored. If `payment_type` is set to `Subscription`, `gateway_class` cannot be modified.
506
+ :param pulumi.Input[str] gateway_name: The name of the gateway. The name must be `1` to `60` characters in length and can contain letters, digits, periods (.), underscores (_), and hyphens (-). It must start with a letter.
469
507
  :param pulumi.Input[str] location: The location of the gateway. Valid values: `Cloud`, `On_Premise`.
470
- :param pulumi.Input[str] payment_type: The Payment type of gateway. Valid values: `PayAsYouGo`.
471
- :param pulumi.Input[int] public_network_bandwidth: The public network bandwidth of gateway. Default value: `5`. Valid values: `5` to `200`.
472
- :param pulumi.Input[str] reason_detail: The reason detail of gateway.
473
- :param pulumi.Input[str] reason_type: The reason type when user deletes the gateway.
474
- :param pulumi.Input[bool] release_after_expiration: Whether to release the gateway due to expiration.
508
+ :param pulumi.Input[str] payment_type: The Payment type of gateway. Valid values: `PayAsYouGo`, `Subscription`. **NOTE:** From version 1.233.0, `payment_type` can be set to `Subscription`.
509
+ :param pulumi.Input[int] public_network_bandwidth: The public bandwidth of the gateway. Default value: `5`. Valid values: `5` to `200`. **NOTE:** `public_network_bandwidth` is only valid when `location` is `Cloud`. If `payment_type` is set to `Subscription`, `public_network_bandwidth` cannot be modified.
510
+ :param pulumi.Input[str] reason_detail: The detailed reason why you want to delete the gateway.
511
+ :param pulumi.Input[str] reason_type: The type of the reason why you want to delete the gateway.
512
+ :param pulumi.Input[bool] release_after_expiration: Specifies whether to release the gateway after the subscription expires. Valid values:
475
513
  :param pulumi.Input[str] storage_bundle_id: The ID of the gateway cluster.
476
514
  :param pulumi.Input[str] type: The type of the gateway. Valid values: `File`, `Iscsi`.
477
- :param pulumi.Input[str] vswitch_id: The ID of the vSwitch.
515
+ :param pulumi.Input[str] vswitch_id: The ID of the VSwitch. **NOTE:** If `location` is set to `Cloud`, `vswitch_id` is required. Otherwise, `vswitch_id` will be ignored.
478
516
  """
479
517
  ...
480
518
  @overload
@@ -485,10 +523,48 @@ class Gateway(pulumi.CustomResource):
485
523
  """
486
524
  Provides a Cloud Storage Gateway Gateway resource.
487
525
 
488
- For information about Cloud Storage Gateway Gateway and how to use it, see [What is Gateway](https://www.alibabacloud.com/help/en/cloud-storage-gateway/latest/deploygateway).
526
+ For information about Cloud Storage Gateway Gateway and how to use it, see [What is Gateway](https://www.alibabacloud.com/help/en/csg/developer-reference/api-mnz46x).
489
527
 
490
528
  > **NOTE:** Available since v1.132.0.
491
529
 
530
+ ## Example Usage
531
+
532
+ Basic Usage
533
+
534
+ ```python
535
+ import pulumi
536
+ import pulumi_alicloud as alicloud
537
+ import pulumi_random as random
538
+
539
+ config = pulumi.Config()
540
+ name = config.get("name")
541
+ if name is None:
542
+ name = "terraform-example"
543
+ default = alicloud.get_zones()
544
+ default_integer = random.index.Integer("default",
545
+ min=10000,
546
+ max=99999)
547
+ default_storage_bundle = alicloud.cloudstoragegateway.StorageBundle("default", storage_bundle_name=f"{name}-{default_integer['result']}")
548
+ default_network = alicloud.vpc.Network("default",
549
+ vpc_name=f"{name}-{default_integer['result']}",
550
+ cidr_block="192.168.0.0/16")
551
+ default_switch = alicloud.vpc.Switch("default",
552
+ vswitch_name=f"{name}-{default_integer['result']}",
553
+ vpc_id=default_network.id,
554
+ cidr_block="192.168.192.0/24",
555
+ zone_id=default.zones[0].id)
556
+ default_gateway = alicloud.cloudstoragegateway.Gateway("default",
557
+ storage_bundle_id=default_storage_bundle.id,
558
+ type="File",
559
+ location="Cloud",
560
+ gateway_name=name,
561
+ gateway_class="Standard",
562
+ vswitch_id=default_switch.id,
563
+ public_network_bandwidth=50,
564
+ payment_type="PayAsYouGo",
565
+ description=name)
566
+ ```
567
+
492
568
  ## Import
493
569
 
494
570
  Cloud Storage Gateway Gateway can be imported using the id, e.g.
@@ -585,18 +661,18 @@ class Gateway(pulumi.CustomResource):
585
661
  :param pulumi.Input[str] id: The unique provider ID of the resource to lookup.
586
662
  :param pulumi.ResourceOptions opts: Options for the resource.
587
663
  :param pulumi.Input[str] description: The description of the gateway.
588
- :param pulumi.Input[str] gateway_class: The specification of the gateway. Valid values: `Basic`, `Standard`,`Enhanced`,`Advanced`.
589
- :param pulumi.Input[str] gateway_name: The name of the gateway.
664
+ :param pulumi.Input[str] gateway_class: The specification of the gateway. Valid values: `Basic`, `Standard`, `Enhanced`, `Advanced`. **NOTE:** If `location` is set to `Cloud`, `gateway_class` is required. Otherwise, `gateway_class` will be ignored. If `payment_type` is set to `Subscription`, `gateway_class` cannot be modified.
665
+ :param pulumi.Input[str] gateway_name: The name of the gateway. The name must be `1` to `60` characters in length and can contain letters, digits, periods (.), underscores (_), and hyphens (-). It must start with a letter.
590
666
  :param pulumi.Input[str] location: The location of the gateway. Valid values: `Cloud`, `On_Premise`.
591
- :param pulumi.Input[str] payment_type: The Payment type of gateway. Valid values: `PayAsYouGo`.
592
- :param pulumi.Input[int] public_network_bandwidth: The public network bandwidth of gateway. Default value: `5`. Valid values: `5` to `200`.
593
- :param pulumi.Input[str] reason_detail: The reason detail of gateway.
594
- :param pulumi.Input[str] reason_type: The reason type when user deletes the gateway.
595
- :param pulumi.Input[bool] release_after_expiration: Whether to release the gateway due to expiration.
667
+ :param pulumi.Input[str] payment_type: The Payment type of gateway. Valid values: `PayAsYouGo`, `Subscription`. **NOTE:** From version 1.233.0, `payment_type` can be set to `Subscription`.
668
+ :param pulumi.Input[int] public_network_bandwidth: The public bandwidth of the gateway. Default value: `5`. Valid values: `5` to `200`. **NOTE:** `public_network_bandwidth` is only valid when `location` is `Cloud`. If `payment_type` is set to `Subscription`, `public_network_bandwidth` cannot be modified.
669
+ :param pulumi.Input[str] reason_detail: The detailed reason why you want to delete the gateway.
670
+ :param pulumi.Input[str] reason_type: The type of the reason why you want to delete the gateway.
671
+ :param pulumi.Input[bool] release_after_expiration: Specifies whether to release the gateway after the subscription expires. Valid values:
596
672
  :param pulumi.Input[str] status: The status of the Gateway.
597
673
  :param pulumi.Input[str] storage_bundle_id: The ID of the gateway cluster.
598
674
  :param pulumi.Input[str] type: The type of the gateway. Valid values: `File`, `Iscsi`.
599
- :param pulumi.Input[str] vswitch_id: The ID of the vSwitch.
675
+ :param pulumi.Input[str] vswitch_id: The ID of the VSwitch. **NOTE:** If `location` is set to `Cloud`, `vswitch_id` is required. Otherwise, `vswitch_id` will be ignored.
600
676
  """
601
677
  opts = pulumi.ResourceOptions.merge(opts, pulumi.ResourceOptions(id=id))
602
678
 
@@ -629,7 +705,7 @@ class Gateway(pulumi.CustomResource):
629
705
  @pulumi.getter(name="gatewayClass")
630
706
  def gateway_class(self) -> pulumi.Output[Optional[str]]:
631
707
  """
632
- The specification of the gateway. Valid values: `Basic`, `Standard`,`Enhanced`,`Advanced`.
708
+ The specification of the gateway. Valid values: `Basic`, `Standard`, `Enhanced`, `Advanced`. **NOTE:** If `location` is set to `Cloud`, `gateway_class` is required. Otherwise, `gateway_class` will be ignored. If `payment_type` is set to `Subscription`, `gateway_class` cannot be modified.
633
709
  """
634
710
  return pulumi.get(self, "gateway_class")
635
711
 
@@ -637,7 +713,7 @@ class Gateway(pulumi.CustomResource):
637
713
  @pulumi.getter(name="gatewayName")
638
714
  def gateway_name(self) -> pulumi.Output[str]:
639
715
  """
640
- The name of the gateway.
716
+ The name of the gateway. The name must be `1` to `60` characters in length and can contain letters, digits, periods (.), underscores (_), and hyphens (-). It must start with a letter.
641
717
  """
642
718
  return pulumi.get(self, "gateway_name")
643
719
 
@@ -653,7 +729,7 @@ class Gateway(pulumi.CustomResource):
653
729
  @pulumi.getter(name="paymentType")
654
730
  def payment_type(self) -> pulumi.Output[Optional[str]]:
655
731
  """
656
- The Payment type of gateway. Valid values: `PayAsYouGo`.
732
+ The Payment type of gateway. Valid values: `PayAsYouGo`, `Subscription`. **NOTE:** From version 1.233.0, `payment_type` can be set to `Subscription`.
657
733
  """
658
734
  return pulumi.get(self, "payment_type")
659
735
 
@@ -661,7 +737,7 @@ class Gateway(pulumi.CustomResource):
661
737
  @pulumi.getter(name="publicNetworkBandwidth")
662
738
  def public_network_bandwidth(self) -> pulumi.Output[int]:
663
739
  """
664
- The public network bandwidth of gateway. Default value: `5`. Valid values: `5` to `200`.
740
+ The public bandwidth of the gateway. Default value: `5`. Valid values: `5` to `200`. **NOTE:** `public_network_bandwidth` is only valid when `location` is `Cloud`. If `payment_type` is set to `Subscription`, `public_network_bandwidth` cannot be modified.
665
741
  """
666
742
  return pulumi.get(self, "public_network_bandwidth")
667
743
 
@@ -669,7 +745,7 @@ class Gateway(pulumi.CustomResource):
669
745
  @pulumi.getter(name="reasonDetail")
670
746
  def reason_detail(self) -> pulumi.Output[Optional[str]]:
671
747
  """
672
- The reason detail of gateway.
748
+ The detailed reason why you want to delete the gateway.
673
749
  """
674
750
  return pulumi.get(self, "reason_detail")
675
751
 
@@ -677,7 +753,7 @@ class Gateway(pulumi.CustomResource):
677
753
  @pulumi.getter(name="reasonType")
678
754
  def reason_type(self) -> pulumi.Output[Optional[str]]:
679
755
  """
680
- The reason type when user deletes the gateway.
756
+ The type of the reason why you want to delete the gateway.
681
757
  """
682
758
  return pulumi.get(self, "reason_type")
683
759
 
@@ -685,7 +761,7 @@ class Gateway(pulumi.CustomResource):
685
761
  @pulumi.getter(name="releaseAfterExpiration")
686
762
  def release_after_expiration(self) -> pulumi.Output[Optional[bool]]:
687
763
  """
688
- Whether to release the gateway due to expiration.
764
+ Specifies whether to release the gateway after the subscription expires. Valid values:
689
765
  """
690
766
  return pulumi.get(self, "release_after_expiration")
691
767
 
@@ -717,7 +793,7 @@ class Gateway(pulumi.CustomResource):
717
793
  @pulumi.getter(name="vswitchId")
718
794
  def vswitch_id(self) -> pulumi.Output[Optional[str]]:
719
795
  """
720
- The ID of the vSwitch.
796
+ The ID of the VSwitch. **NOTE:** If `location` is set to `Cloud`, `vswitch_id` is required. Otherwise, `vswitch_id` will be ignored.
721
797
  """
722
798
  return pulumi.get(self, "vswitch_id")
723
799
 
@@ -177,23 +177,24 @@ class HybridMonitorFcTask(pulumi.CustomResource):
177
177
  specification="cms.s1.large")
178
178
  default_hybrid_monitor_fc_task = alicloud.cms.HybridMonitorFcTask("default",
179
179
  namespace=default_namespace.id,
180
- yarm_config=\"\"\"products:
181
- - namespace: acs_ecs_dashboard
180
+ yarm_config=\"\"\"---
181
+ products:
182
+ - namespace: "acs_ecs_dashboard"
182
183
  metric_info:
183
184
  - metric_list:
184
- - cpu_total
185
- - cpu_idle
186
- - diskusage_utilization
187
- - CPUUtilization
188
- - DiskReadBPS
189
- - InternetOut
190
- - IntranetOut
191
- - cpu_system
192
- - namespace: acs_rds_dashboard
185
+ - "CPUUtilization"
186
+ - "DiskReadBPS"
187
+ - "InternetOut"
188
+ - "IntranetOut"
189
+ - "cpu_idle"
190
+ - "cpu_system"
191
+ - "cpu_total"
192
+ - "diskusage_utilization"
193
+ - namespace: "acs_rds_dashboard"
193
194
  metric_info:
194
195
  - metric_list:
195
- - MySQL_QPS
196
- - MySQL_TPS
196
+ - "MySQL_QPS"
197
+ - "MySQL_TPS"
197
198
  \"\"\",
198
199
  target_user_id=default.id)
199
200
  ```
@@ -244,23 +245,24 @@ class HybridMonitorFcTask(pulumi.CustomResource):
244
245
  specification="cms.s1.large")
245
246
  default_hybrid_monitor_fc_task = alicloud.cms.HybridMonitorFcTask("default",
246
247
  namespace=default_namespace.id,
247
- yarm_config=\"\"\"products:
248
- - namespace: acs_ecs_dashboard
248
+ yarm_config=\"\"\"---
249
+ products:
250
+ - namespace: "acs_ecs_dashboard"
249
251
  metric_info:
250
252
  - metric_list:
251
- - cpu_total
252
- - cpu_idle
253
- - diskusage_utilization
254
- - CPUUtilization
255
- - DiskReadBPS
256
- - InternetOut
257
- - IntranetOut
258
- - cpu_system
259
- - namespace: acs_rds_dashboard
253
+ - "CPUUtilization"
254
+ - "DiskReadBPS"
255
+ - "InternetOut"
256
+ - "IntranetOut"
257
+ - "cpu_idle"
258
+ - "cpu_system"
259
+ - "cpu_total"
260
+ - "diskusage_utilization"
261
+ - namespace: "acs_rds_dashboard"
260
262
  metric_info:
261
263
  - metric_list:
262
- - MySQL_QPS
263
- - MySQL_TPS
264
+ - "MySQL_QPS"
265
+ - "MySQL_TPS"
264
266
  \"\"\",
265
267
  target_user_id=default.id)
266
268
  ```
@@ -266,27 +266,31 @@ class Chain(pulumi.CustomResource):
266
266
  ```python
267
267
  import pulumi
268
268
  import pulumi_alicloud as alicloud
269
+ import pulumi_random as random
269
270
 
270
271
  config = pulumi.Config()
271
272
  name = config.get("name")
272
273
  if name is None:
273
274
  name = "tf-example"
274
- default = alicloud.cr.RegistryEnterpriseInstance("default",
275
+ default = random.index.Integer("default",
276
+ min=100000,
277
+ max=999999)
278
+ default_registry_enterprise_instance = alicloud.cr.RegistryEnterpriseInstance("default",
275
279
  payment_type="Subscription",
276
280
  period=1,
277
281
  renew_period=0,
278
282
  renewal_status="ManualRenewal",
279
283
  instance_type="Advanced",
280
- instance_name=name)
284
+ instance_name=f"{name}-{default['result']}")
281
285
  default_registry_enterprise_namespace = alicloud.cs.RegistryEnterpriseNamespace("default",
282
- instance_id=default.id,
283
- name=name,
286
+ instance_id=default_registry_enterprise_instance.id,
287
+ name=f"{name}-{default['result']}",
284
288
  auto_create=False,
285
289
  default_visibility="PUBLIC")
286
290
  default_registry_enterprise_repo = alicloud.cs.RegistryEnterpriseRepo("default",
287
- instance_id=default.id,
291
+ instance_id=default_registry_enterprise_instance.id,
288
292
  namespace=default_registry_enterprise_namespace.name,
289
- name=name,
293
+ name=f"{name}-{default['result']}",
290
294
  summary="this is summary of my new repo",
291
295
  repo_type="PUBLIC",
292
296
  detail="this is a public repo")
@@ -399,7 +403,7 @@ class Chain(pulumi.CustomResource):
399
403
  },
400
404
  ],
401
405
  }],
402
- chain_name=name,
406
+ chain_name=f"{name}-{default['result']}",
403
407
  description=name,
404
408
  instance_id=default_registry_enterprise_namespace.instance_id,
405
409
  repo_name=default_registry_enterprise_repo.name,
@@ -443,27 +447,31 @@ class Chain(pulumi.CustomResource):
443
447
  ```python
444
448
  import pulumi
445
449
  import pulumi_alicloud as alicloud
450
+ import pulumi_random as random
446
451
 
447
452
  config = pulumi.Config()
448
453
  name = config.get("name")
449
454
  if name is None:
450
455
  name = "tf-example"
451
- default = alicloud.cr.RegistryEnterpriseInstance("default",
456
+ default = random.index.Integer("default",
457
+ min=100000,
458
+ max=999999)
459
+ default_registry_enterprise_instance = alicloud.cr.RegistryEnterpriseInstance("default",
452
460
  payment_type="Subscription",
453
461
  period=1,
454
462
  renew_period=0,
455
463
  renewal_status="ManualRenewal",
456
464
  instance_type="Advanced",
457
- instance_name=name)
465
+ instance_name=f"{name}-{default['result']}")
458
466
  default_registry_enterprise_namespace = alicloud.cs.RegistryEnterpriseNamespace("default",
459
- instance_id=default.id,
460
- name=name,
467
+ instance_id=default_registry_enterprise_instance.id,
468
+ name=f"{name}-{default['result']}",
461
469
  auto_create=False,
462
470
  default_visibility="PUBLIC")
463
471
  default_registry_enterprise_repo = alicloud.cs.RegistryEnterpriseRepo("default",
464
- instance_id=default.id,
472
+ instance_id=default_registry_enterprise_instance.id,
465
473
  namespace=default_registry_enterprise_namespace.name,
466
- name=name,
474
+ name=f"{name}-{default['result']}",
467
475
  summary="this is summary of my new repo",
468
476
  repo_type="PUBLIC",
469
477
  detail="this is a public repo")
@@ -576,7 +584,7 @@ class Chain(pulumi.CustomResource):
576
584
  },
577
585
  ],
578
586
  }],
579
- chain_name=name,
587
+ chain_name=f"{name}-{default['result']}",
580
588
  description=name,
581
589
  instance_id=default_registry_enterprise_namespace.instance_id,
582
590
  repo_name=default_registry_enterprise_repo.name,