Skip to content

Commit 0b955e3

Browse files
sync examples from Provider v1.265.0
1 parent dfff9ed commit 0b955e3

File tree

14 files changed

+342
-1
lines changed

14 files changed

+342
-1
lines changed
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
## Introduction
2+
3+
This example is used to create a `alicloud_cr_scan_rule` resource.
4+
5+
<!-- BEGIN_TF_DOCS -->
6+
## Providers
7+
8+
| Name | Version |
9+
|------|---------|
10+
| <a name="provider_alicloud"></a> [alicloud](#provider\_alicloud) | n/a |
11+
12+
## Modules
13+
14+
No modules.
15+
16+
## Resources
17+
18+
| Name | Type |
19+
|------|------|
20+
| [alicloud_cr_ee_instance.default2Aqoce](https://registry.terraform.io/providers/aliyun/alicloud/latest/docs/resources/cr_ee_instance) | resource |
21+
| [alicloud_cr_scan_rule.default](https://registry.terraform.io/providers/aliyun/alicloud/latest/docs/resources/cr_scan_rule) | resource |
22+
23+
## Inputs
24+
25+
| Name | Description | Type | Default | Required |
26+
|------|-------------|------|---------|:--------:|
27+
| <a name="input_name"></a> [name](#input\_name) | n/a | `string` | `"terraform-example"` | no |
28+
<!-- END_TF_DOCS -->
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
variable "name" {
2+
default = "terraform-example"
3+
}
4+
5+
provider "alicloud" {
6+
region = "cn-hangzhou"
7+
}
8+
9+
resource "alicloud_cr_ee_instance" "default2Aqoce" {
10+
default_oss_bucket = "false"
11+
renewal_status = "ManualRenewal"
12+
period = "1"
13+
instance_name = "pl-example-2"
14+
payment_type = "Subscription"
15+
instance_type = "Basic"
16+
}
17+
18+
19+
resource "alicloud_cr_scan_rule" "default" {
20+
repo_tag_filter_pattern = ".*"
21+
scan_scope = "REPO"
22+
trigger_type = "MANUAL"
23+
scan_type = "VUL"
24+
rule_name = var.name
25+
namespaces = ["aa"]
26+
repo_names = ["bb", "cc", "dd", "ee"]
27+
instance_id = alicloud_cr_ee_instance.default2Aqoce.id
28+
}
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
terraform {
2+
required_providers {
3+
alicloud = {
4+
source = "aliyun/alicloud"
5+
}
6+
}
7+
}
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
## Introduction
2+
3+
This example is used to create a `alicloud_cr_storage_domain_routing_rule` resource.
4+
5+
<!-- BEGIN_TF_DOCS -->
6+
## Providers
7+
8+
| Name | Version |
9+
|------|---------|
10+
| <a name="provider_alicloud"></a> [alicloud](#provider\_alicloud) | n/a |
11+
12+
## Modules
13+
14+
No modules.
15+
16+
## Resources
17+
18+
| Name | Type |
19+
|------|------|
20+
| [alicloud_cr_ee_instance.default](https://registry.terraform.io/providers/aliyun/alicloud/latest/docs/resources/cr_ee_instance) | resource |
21+
| [alicloud_cr_storage_domain_routing_rule.default](https://registry.terraform.io/providers/aliyun/alicloud/latest/docs/resources/cr_storage_domain_routing_rule) | resource |
22+
23+
## Inputs
24+
25+
| Name | Description | Type | Default | Required |
26+
|------|-------------|------|---------|:--------:|
27+
| <a name="input_name"></a> [name](#input\_name) | n/a | `string` | `"terraform-example"` | no |
28+
<!-- END_TF_DOCS -->
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
variable "name" {
2+
default = "terraform-example"
3+
}
4+
5+
provider "alicloud" {
6+
region = "cn-hangzhou"
7+
}
8+
9+
resource "alicloud_cr_ee_instance" "default" {
10+
payment_type = "Subscription"
11+
period = 1
12+
renew_period = 1
13+
renewal_status = "AutoRenewal"
14+
instance_type = "Advanced"
15+
instance_name = var.name
16+
}
17+
18+
resource "alicloud_cr_storage_domain_routing_rule" "default" {
19+
routes {
20+
instance_domain = "${alicloud_cr_ee_instance.default.instance_name}-registry-vpc.cn-hangzhou.cr.aliyuncs.com"
21+
storage_domain = "https://${alicloud_cr_ee_instance.default.id}-registry.oss-cn-hangzhou-internal.aliyuncs.com"
22+
endpoint_type = "Internet"
23+
}
24+
instance_id = alicloud_cr_ee_instance.default.id
25+
}
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
terraform {
2+
required_providers {
3+
alicloud = {
4+
source = "aliyun/alicloud"
5+
}
6+
}
7+
}

quickstarts/ESA/101-esa-edge-container-app-record-docs-Example/main.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ resource "alicloud_esa_edge_container_app" "default" {
2323
health_check_type = "l7"
2424
service_port = "80"
2525
health_check_interval = "5"
26-
edge_container_app_name = "terraform-app"
26+
edge_container_app_name = "terraform-app2"
2727
health_check_http_code = "http_2xx"
2828
health_check_uri = "/"
2929
health_check_timeout = "3"

quickstarts/ESA/101-esa-transport-layer-application-docs-Example/main.tf

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ variable "name" {
44

55
data "alicloud_esa_sites" "default" {
66
plan_subscribe_type = "enterpriseplan"
7+
site_name = "gositecdn.cn"
78
}
89

910
resource "alicloud_esa_transport_layer_application" "default" {
Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
## Introduction
2+
3+
This example is used to create a `alicloud_realtime_compute_deployment` resource.
4+
5+
<!-- BEGIN_TF_DOCS -->
6+
## Providers
7+
8+
| Name | Version |
9+
|------|---------|
10+
| <a name="provider_alicloud"></a> [alicloud](#provider\_alicloud) | n/a |
11+
12+
## Modules
13+
14+
No modules.
15+
16+
## Resources
17+
18+
| Name | Type |
19+
|------|------|
20+
| [alicloud_oss_bucket.default](https://registry.terraform.io/providers/aliyun/alicloud/latest/docs/resources/oss_bucket) | resource |
21+
| [alicloud_realtime_compute_deployment.create_Deployment9](https://registry.terraform.io/providers/aliyun/alicloud/latest/docs/resources/realtime_compute_deployment) | resource |
22+
| [alicloud_realtime_compute_vvp_instance.default](https://registry.terraform.io/providers/aliyun/alicloud/latest/docs/resources/realtime_compute_vvp_instance) | resource |
23+
| [alicloud_vpc.default](https://registry.terraform.io/providers/aliyun/alicloud/latest/docs/resources/vpc) | resource |
24+
| [alicloud_vswitch.default](https://registry.terraform.io/providers/aliyun/alicloud/latest/docs/resources/vswitch) | resource |
25+
26+
## Inputs
27+
28+
| Name | Description | Type | Default | Required |
29+
|------|-------------|------|---------|:--------:|
30+
| <a name="input_name"></a> [name](#input\_name) | n/a | `string` | `"terraform-example"` | no |
31+
<!-- END_TF_DOCS -->
Lines changed: 59 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,59 @@
1+
variable "name" {
2+
default = "terraform-example"
3+
}
4+
5+
provider "alicloud" {
6+
region = "cn-beijing"
7+
}
8+
9+
resource "alicloud_vpc" "default" {
10+
is_default = false
11+
cidr_block = "172.16.0.0/16"
12+
vpc_name = "example-tf-vpc-deployment"
13+
}
14+
15+
resource "alicloud_vswitch" "default" {
16+
is_default = false
17+
vpc_id = alicloud_vpc.default.id
18+
zone_id = "cn-beijing-g"
19+
cidr_block = "172.16.0.0/24"
20+
vswitch_name = "example-tf-vSwitch-deployment"
21+
}
22+
23+
resource "alicloud_oss_bucket" "default" {
24+
}
25+
26+
resource "alicloud_realtime_compute_vvp_instance" "default" {
27+
vvp_instance_name = "code-example-tf-deployment"
28+
storage {
29+
oss {
30+
bucket = alicloud_oss_bucket.default.id
31+
}
32+
}
33+
vpc_id = alicloud_vpc.default.id
34+
vswitch_ids = ["${alicloud_vswitch.default.id}"]
35+
resource_spec {
36+
cpu = "8"
37+
memory_gb = "32"
38+
}
39+
payment_type = "PayAsYouGo"
40+
zone_id = alicloud_vswitch.default.zone_id
41+
}
42+
43+
resource "alicloud_realtime_compute_deployment" "create_Deployment9" {
44+
deployment_name = "tf-example-deployment-sql-56"
45+
engine_version = "vvr-8.0.10-flink-1.17"
46+
resource_id = alicloud_realtime_compute_vvp_instance.default.resource_id
47+
execution_mode = "STREAMING"
48+
deployment_target {
49+
mode = "PER_JOB"
50+
name = "default-queue"
51+
}
52+
namespace = "${alicloud_realtime_compute_vvp_instance.default.vvp_instance_name}-default"
53+
artifact {
54+
kind = "SQLSCRIPT"
55+
sql_artifact {
56+
sql_script = "create temporary table `datagen` ( id varchar, name varchar ) with ( 'connector' = 'datagen' ); create temporary table `blackhole` ( id varchar, name varchar ) with ( 'connector' = 'blackhole' ); insert into blackhole select * from datagen;"
57+
}
58+
}
59+
}

0 commit comments

Comments
 (0)