tencentcloud.ClbCustomizedConfig
Explore with Pulumi AI
Provides a resource to create a CLB customized config which type is CLB
.
Example Usage
Create clb customized config without CLB instance
import * as pulumi from "@pulumi/pulumi";
import * as tencentcloud from "@pulumi/tencentcloud";
const example = new tencentcloud.ClbCustomizedConfig("example", {
configContent: `client_max_body_size 224M;\x0d
client_body_timeout 60s;
`,
configName: "tf-example",
});
import pulumi
import pulumi_tencentcloud as tencentcloud
example = tencentcloud.ClbCustomizedConfig("example",
config_content="""client_max_body_size 224M;\x0d
client_body_timeout 60s;
""",
config_name="tf-example")
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.NewClbCustomizedConfig(ctx, "example", &tencentcloud.ClbCustomizedConfigArgs{
ConfigContent: pulumi.String("client_max_body_size 224M;
\nclient_body_timeout 60s;\n"),
ConfigName: pulumi.String("tf-example"),
})
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.ClbCustomizedConfig("example", new()
{
ConfigContent = @"client_max_body_size 224M;
client_body_timeout 60s;
",
ConfigName = "tf-example",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.tencentcloud.ClbCustomizedConfig;
import com.pulumi.tencentcloud.ClbCustomizedConfigArgs;
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 ClbCustomizedConfig("example", ClbCustomizedConfigArgs.builder()
.configContent("""
client_max_body_size 224M;
client_body_timeout 60s;
""")
.configName("tf-example")
.build());
}
}
resources:
example:
type: tencentcloud:ClbCustomizedConfig
properties:
configContent: "client_max_body_size 224M;\r\nclient_body_timeout 60s;\n"
configName: tf-example
Create clb customized config with CLB instances
import * as pulumi from "@pulumi/pulumi";
import * as tencentcloud from "@pulumi/tencentcloud";
const example = new tencentcloud.ClbCustomizedConfig("example", {
configContent: `client_max_body_size 224M;\x0d
client_body_timeout 60s;
`,
configName: "tf-example",
loadBalancerIds: [
"lb-l6cp6jt4",
"lb-muk4zzxi",
],
});
import pulumi
import pulumi_tencentcloud as tencentcloud
example = tencentcloud.ClbCustomizedConfig("example",
config_content="""client_max_body_size 224M;\x0d
client_body_timeout 60s;
""",
config_name="tf-example",
load_balancer_ids=[
"lb-l6cp6jt4",
"lb-muk4zzxi",
])
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.NewClbCustomizedConfig(ctx, "example", &tencentcloud.ClbCustomizedConfigArgs{
ConfigContent: pulumi.String("client_max_body_size 224M;
\nclient_body_timeout 60s;\n"),
ConfigName: pulumi.String("tf-example"),
LoadBalancerIds: pulumi.StringArray{
pulumi.String("lb-l6cp6jt4"),
pulumi.String("lb-muk4zzxi"),
},
})
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.ClbCustomizedConfig("example", new()
{
ConfigContent = @"client_max_body_size 224M;
client_body_timeout 60s;
",
ConfigName = "tf-example",
LoadBalancerIds = new[]
{
"lb-l6cp6jt4",
"lb-muk4zzxi",
},
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.tencentcloud.ClbCustomizedConfig;
import com.pulumi.tencentcloud.ClbCustomizedConfigArgs;
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 ClbCustomizedConfig("example", ClbCustomizedConfigArgs.builder()
.configContent("""
client_max_body_size 224M;
client_body_timeout 60s;
""")
.configName("tf-example")
.loadBalancerIds(
"lb-l6cp6jt4",
"lb-muk4zzxi")
.build());
}
}
resources:
example:
type: tencentcloud:ClbCustomizedConfig
properties:
configContent: "client_max_body_size 224M;\r\nclient_body_timeout 60s;\n"
configName: tf-example
loadBalancerIds:
- lb-l6cp6jt4
- lb-muk4zzxi
Create ClbCustomizedConfig Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new ClbCustomizedConfig(name: string, args: ClbCustomizedConfigArgs, opts?: CustomResourceOptions);
@overload
def ClbCustomizedConfig(resource_name: str,
args: ClbCustomizedConfigArgs,
opts: Optional[ResourceOptions] = None)
@overload
def ClbCustomizedConfig(resource_name: str,
opts: Optional[ResourceOptions] = None,
config_content: Optional[str] = None,
config_name: Optional[str] = None,
clb_customized_config_id: Optional[str] = None,
load_balancer_ids: Optional[Sequence[str]] = None)
func NewClbCustomizedConfig(ctx *Context, name string, args ClbCustomizedConfigArgs, opts ...ResourceOption) (*ClbCustomizedConfig, error)
public ClbCustomizedConfig(string name, ClbCustomizedConfigArgs args, CustomResourceOptions? opts = null)
public ClbCustomizedConfig(String name, ClbCustomizedConfigArgs args)
public ClbCustomizedConfig(String name, ClbCustomizedConfigArgs args, CustomResourceOptions options)
type: tencentcloud:ClbCustomizedConfig
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 ClbCustomizedConfigArgs
- 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 ClbCustomizedConfigArgs
- 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 ClbCustomizedConfigArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args ClbCustomizedConfigArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args ClbCustomizedConfigArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
ClbCustomizedConfig 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 ClbCustomizedConfig resource accepts the following input properties:
- Config
Content string - Content of Customized Config.
- Config
Name string - Name of Customized Config.
- Clb
Customized stringConfig Id - ID of the resource.
- Load
Balancer List<string>Ids - List of LoadBalancer Ids.
- Config
Content string - Content of Customized Config.
- Config
Name string - Name of Customized Config.
- Clb
Customized stringConfig Id - ID of the resource.
- Load
Balancer []stringIds - List of LoadBalancer Ids.
- config
Content String - Content of Customized Config.
- config
Name String - Name of Customized Config.
- clb
Customized StringConfig Id - ID of the resource.
- load
Balancer List<String>Ids - List of LoadBalancer Ids.
- config
Content string - Content of Customized Config.
- config
Name string - Name of Customized Config.
- clb
Customized stringConfig Id - ID of the resource.
- load
Balancer string[]Ids - List of LoadBalancer Ids.
- config_
content str - Content of Customized Config.
- config_
name str - Name of Customized Config.
- clb_
customized_ strconfig_ id - ID of the resource.
- load_
balancer_ Sequence[str]ids - List of LoadBalancer Ids.
- config
Content String - Content of Customized Config.
- config
Name String - Name of Customized Config.
- clb
Customized StringConfig Id - ID of the resource.
- load
Balancer List<String>Ids - List of LoadBalancer Ids.
Outputs
All input properties are implicitly available as output properties. Additionally, the ClbCustomizedConfig resource produces the following output properties:
- Create
Time string - Create time of Customized Config.
- Id string
- The provider-assigned unique ID for this managed resource.
- Update
Time string - Update time of Customized Config.
- Create
Time string - Create time of Customized Config.
- Id string
- The provider-assigned unique ID for this managed resource.
- Update
Time string - Update time of Customized Config.
- create
Time String - Create time of Customized Config.
- id String
- The provider-assigned unique ID for this managed resource.
- update
Time String - Update time of Customized Config.
- create
Time string - Create time of Customized Config.
- id string
- The provider-assigned unique ID for this managed resource.
- update
Time string - Update time of Customized Config.
- create_
time str - Create time of Customized Config.
- id str
- The provider-assigned unique ID for this managed resource.
- update_
time str - Update time of Customized Config.
- create
Time String - Create time of Customized Config.
- id String
- The provider-assigned unique ID for this managed resource.
- update
Time String - Update time of Customized Config.
Look up Existing ClbCustomizedConfig Resource
Get an existing ClbCustomizedConfig 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?: ClbCustomizedConfigState, opts?: CustomResourceOptions): ClbCustomizedConfig
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
clb_customized_config_id: Optional[str] = None,
config_content: Optional[str] = None,
config_name: Optional[str] = None,
create_time: Optional[str] = None,
load_balancer_ids: Optional[Sequence[str]] = None,
update_time: Optional[str] = None) -> ClbCustomizedConfig
func GetClbCustomizedConfig(ctx *Context, name string, id IDInput, state *ClbCustomizedConfigState, opts ...ResourceOption) (*ClbCustomizedConfig, error)
public static ClbCustomizedConfig Get(string name, Input<string> id, ClbCustomizedConfigState? state, CustomResourceOptions? opts = null)
public static ClbCustomizedConfig get(String name, Output<String> id, ClbCustomizedConfigState state, CustomResourceOptions options)
resources: _: type: tencentcloud:ClbCustomizedConfig 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.
- Clb
Customized stringConfig Id - ID of the resource.
- Config
Content string - Content of Customized Config.
- Config
Name string - Name of Customized Config.
- Create
Time string - Create time of Customized Config.
- Load
Balancer List<string>Ids - List of LoadBalancer Ids.
- Update
Time string - Update time of Customized Config.
- Clb
Customized stringConfig Id - ID of the resource.
- Config
Content string - Content of Customized Config.
- Config
Name string - Name of Customized Config.
- Create
Time string - Create time of Customized Config.
- Load
Balancer []stringIds - List of LoadBalancer Ids.
- Update
Time string - Update time of Customized Config.
- clb
Customized StringConfig Id - ID of the resource.
- config
Content String - Content of Customized Config.
- config
Name String - Name of Customized Config.
- create
Time String - Create time of Customized Config.
- load
Balancer List<String>Ids - List of LoadBalancer Ids.
- update
Time String - Update time of Customized Config.
- clb
Customized stringConfig Id - ID of the resource.
- config
Content string - Content of Customized Config.
- config
Name string - Name of Customized Config.
- create
Time string - Create time of Customized Config.
- load
Balancer string[]Ids - List of LoadBalancer Ids.
- update
Time string - Update time of Customized Config.
- clb_
customized_ strconfig_ id - ID of the resource.
- config_
content str - Content of Customized Config.
- config_
name str - Name of Customized Config.
- create_
time str - Create time of Customized Config.
- load_
balancer_ Sequence[str]ids - List of LoadBalancer Ids.
- update_
time str - Update time of Customized Config.
- clb
Customized StringConfig Id - ID of the resource.
- config
Content String - Content of Customized Config.
- config
Name String - Name of Customized Config.
- create
Time String - Create time of Customized Config.
- load
Balancer List<String>Ids - List of LoadBalancer Ids.
- update
Time String - Update time of Customized Config.
Import
CLB customized config can be imported using the id, e.g.
$ pulumi import tencentcloud:index/clbCustomizedConfig:ClbCustomizedConfig example pz-diowqstq
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.