tencentcloud.CfwAddressTemplate
Explore with Pulumi AI
Provides a resource to create a cfw address_template
Example Usage
If type is 1
import * as pulumi from "@pulumi/pulumi";
import * as tencentcloud from "@pulumi/tencentcloud";
const example = new tencentcloud.CfwAddressTemplate("example", {
detail: "test template",
ipString: "1.1.1.1,2.2.2.2",
type: 1,
});
import pulumi
import pulumi_tencentcloud as tencentcloud
example = tencentcloud.CfwAddressTemplate("example",
detail="test template",
ip_string="1.1.1.1,2.2.2.2",
type=1)
package main
import (
"github.com/pulumi/pulumi-terraform-provider/sdks/go/tencentcloud/tencentcloud"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := tencentcloud.NewCfwAddressTemplate(ctx, "example", &tencentcloud.CfwAddressTemplateArgs{
Detail: pulumi.String("test template"),
IpString: pulumi.String("1.1.1.1,2.2.2.2"),
Type: pulumi.Float64(1),
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Tencentcloud = Pulumi.Tencentcloud;
return await Deployment.RunAsync(() =>
{
var example = new Tencentcloud.CfwAddressTemplate("example", new()
{
Detail = "test template",
IpString = "1.1.1.1,2.2.2.2",
Type = 1,
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.tencentcloud.CfwAddressTemplate;
import com.pulumi.tencentcloud.CfwAddressTemplateArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var example = new CfwAddressTemplate("example", CfwAddressTemplateArgs.builder()
.detail("test template")
.ipString("1.1.1.1,2.2.2.2")
.type(1)
.build());
}
}
resources:
example:
type: tencentcloud:CfwAddressTemplate
properties:
detail: test template
ipString: 1.1.1.1,2.2.2.2
type: 1
If type is 5
import * as pulumi from "@pulumi/pulumi";
import * as tencentcloud from "@pulumi/tencentcloud";
const example = new tencentcloud.CfwAddressTemplate("example", {
detail: "test template",
ipString: "www.qq.com,www.tencent.com",
type: 5,
});
import pulumi
import pulumi_tencentcloud as tencentcloud
example = tencentcloud.CfwAddressTemplate("example",
detail="test template",
ip_string="www.qq.com,www.tencent.com",
type=5)
package main
import (
"github.com/pulumi/pulumi-terraform-provider/sdks/go/tencentcloud/tencentcloud"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := tencentcloud.NewCfwAddressTemplate(ctx, "example", &tencentcloud.CfwAddressTemplateArgs{
Detail: pulumi.String("test template"),
IpString: pulumi.String("www.qq.com,www.tencent.com"),
Type: pulumi.Float64(5),
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Tencentcloud = Pulumi.Tencentcloud;
return await Deployment.RunAsync(() =>
{
var example = new Tencentcloud.CfwAddressTemplate("example", new()
{
Detail = "test template",
IpString = "www.qq.com,www.tencent.com",
Type = 5,
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.tencentcloud.CfwAddressTemplate;
import com.pulumi.tencentcloud.CfwAddressTemplateArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var example = new CfwAddressTemplate("example", CfwAddressTemplateArgs.builder()
.detail("test template")
.ipString("www.qq.com,www.tencent.com")
.type(5)
.build());
}
}
resources:
example:
type: tencentcloud:CfwAddressTemplate
properties:
detail: test template
ipString: www.qq.com,www.tencent.com
type: 5
Create CfwAddressTemplate Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new CfwAddressTemplate(name: string, args: CfwAddressTemplateArgs, opts?: CustomResourceOptions);
@overload
def CfwAddressTemplate(resource_name: str,
args: CfwAddressTemplateArgs,
opts: Optional[ResourceOptions] = None)
@overload
def CfwAddressTemplate(resource_name: str,
opts: Optional[ResourceOptions] = None,
detail: Optional[str] = None,
ip_string: Optional[str] = None,
type: Optional[float] = None,
cfw_address_template_id: Optional[str] = None,
name: Optional[str] = None)
func NewCfwAddressTemplate(ctx *Context, name string, args CfwAddressTemplateArgs, opts ...ResourceOption) (*CfwAddressTemplate, error)
public CfwAddressTemplate(string name, CfwAddressTemplateArgs args, CustomResourceOptions? opts = null)
public CfwAddressTemplate(String name, CfwAddressTemplateArgs args)
public CfwAddressTemplate(String name, CfwAddressTemplateArgs args, CustomResourceOptions options)
type: tencentcloud:CfwAddressTemplate
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args CfwAddressTemplateArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args CfwAddressTemplateArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args CfwAddressTemplateArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args CfwAddressTemplateArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args CfwAddressTemplateArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
CfwAddressTemplate Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The CfwAddressTemplate resource accepts the following input properties:
- Detail string
- Template Detail.
- Ip
String string - Type is 1, ip template eg: 1.1.1.1,2.2.2.2; Type is 5, domain name template eg: www.qq.com, www.tencent.com.
- Type double
- 1: ip template; 5: domain name templates.
- Cfw
Address stringTemplate Id - ID of the resource.
- Name string
- Template name.
- Detail string
- Template Detail.
- Ip
String string - Type is 1, ip template eg: 1.1.1.1,2.2.2.2; Type is 5, domain name template eg: www.qq.com, www.tencent.com.
- Type float64
- 1: ip template; 5: domain name templates.
- Cfw
Address stringTemplate Id - ID of the resource.
- Name string
- Template name.
- detail String
- Template Detail.
- ip
String String - Type is 1, ip template eg: 1.1.1.1,2.2.2.2; Type is 5, domain name template eg: www.qq.com, www.tencent.com.
- type Double
- 1: ip template; 5: domain name templates.
- cfw
Address StringTemplate Id - ID of the resource.
- name String
- Template name.
- detail string
- Template Detail.
- ip
String string - Type is 1, ip template eg: 1.1.1.1,2.2.2.2; Type is 5, domain name template eg: www.qq.com, www.tencent.com.
- type number
- 1: ip template; 5: domain name templates.
- cfw
Address stringTemplate Id - ID of the resource.
- name string
- Template name.
- detail str
- Template Detail.
- ip_
string str - Type is 1, ip template eg: 1.1.1.1,2.2.2.2; Type is 5, domain name template eg: www.qq.com, www.tencent.com.
- type float
- 1: ip template; 5: domain name templates.
- cfw_
address_ strtemplate_ id - ID of the resource.
- name str
- Template name.
- detail String
- Template Detail.
- ip
String String - Type is 1, ip template eg: 1.1.1.1,2.2.2.2; Type is 5, domain name template eg: www.qq.com, www.tencent.com.
- type Number
- 1: ip template; 5: domain name templates.
- cfw
Address StringTemplate Id - ID of the resource.
- name String
- Template name.
Outputs
All input properties are implicitly available as output properties. Additionally, the CfwAddressTemplate resource produces the following output properties:
- Id string
- The provider-assigned unique ID for this managed resource.
- Id string
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
- id string
- The provider-assigned unique ID for this managed resource.
- id str
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
Look up Existing CfwAddressTemplate Resource
Get an existing CfwAddressTemplate resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.
public static get(name: string, id: Input<ID>, state?: CfwAddressTemplateState, opts?: CustomResourceOptions): CfwAddressTemplate
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
cfw_address_template_id: Optional[str] = None,
detail: Optional[str] = None,
ip_string: Optional[str] = None,
name: Optional[str] = None,
type: Optional[float] = None) -> CfwAddressTemplate
func GetCfwAddressTemplate(ctx *Context, name string, id IDInput, state *CfwAddressTemplateState, opts ...ResourceOption) (*CfwAddressTemplate, error)
public static CfwAddressTemplate Get(string name, Input<string> id, CfwAddressTemplateState? state, CustomResourceOptions? opts = null)
public static CfwAddressTemplate get(String name, Output<String> id, CfwAddressTemplateState state, CustomResourceOptions options)
resources: _: type: tencentcloud:CfwAddressTemplate get: id: ${id}
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- resource_name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- Cfw
Address stringTemplate Id - ID of the resource.
- Detail string
- Template Detail.
- Ip
String string - Type is 1, ip template eg: 1.1.1.1,2.2.2.2; Type is 5, domain name template eg: www.qq.com, www.tencent.com.
- Name string
- Template name.
- Type double
- 1: ip template; 5: domain name templates.
- Cfw
Address stringTemplate Id - ID of the resource.
- Detail string
- Template Detail.
- Ip
String string - Type is 1, ip template eg: 1.1.1.1,2.2.2.2; Type is 5, domain name template eg: www.qq.com, www.tencent.com.
- Name string
- Template name.
- Type float64
- 1: ip template; 5: domain name templates.
- cfw
Address StringTemplate Id - ID of the resource.
- detail String
- Template Detail.
- ip
String String - Type is 1, ip template eg: 1.1.1.1,2.2.2.2; Type is 5, domain name template eg: www.qq.com, www.tencent.com.
- name String
- Template name.
- type Double
- 1: ip template; 5: domain name templates.
- cfw
Address stringTemplate Id - ID of the resource.
- detail string
- Template Detail.
- ip
String string - Type is 1, ip template eg: 1.1.1.1,2.2.2.2; Type is 5, domain name template eg: www.qq.com, www.tencent.com.
- name string
- Template name.
- type number
- 1: ip template; 5: domain name templates.
- cfw_
address_ strtemplate_ id - ID of the resource.
- detail str
- Template Detail.
- ip_
string str - Type is 1, ip template eg: 1.1.1.1,2.2.2.2; Type is 5, domain name template eg: www.qq.com, www.tencent.com.
- name str
- Template name.
- type float
- 1: ip template; 5: domain name templates.
- cfw
Address StringTemplate Id - ID of the resource.
- detail String
- Template Detail.
- ip
String String - Type is 1, ip template eg: 1.1.1.1,2.2.2.2; Type is 5, domain name template eg: www.qq.com, www.tencent.com.
- name String
- Template name.
- type Number
- 1: ip template; 5: domain name templates.
Import
cfw address_template can be imported using the id, e.g.
$ pulumi import tencentcloud:index/cfwAddressTemplate:CfwAddressTemplate example mb_1300846651_1695611353900
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- tencentcloud tencentcloudstack/terraform-provider-tencentcloud
- License
- Notes
- This Pulumi package is based on the
tencentcloud
Terraform Provider.