1. Packages
  2. Tencentcloud Provider
  3. API Docs
  4. TcmAccessLogConfig
tencentcloud 1.81.189 published on Wednesday, Apr 30, 2025 by tencentcloudstack

tencentcloud.TcmAccessLogConfig

Explore with Pulumi AI

tencentcloud logo
tencentcloud 1.81.189 published on Wednesday, Apr 30, 2025 by tencentcloudstack

    Provides a resource to create a tcm access_log_config

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as tencentcloud from "@pulumi/tencentcloud";
    
    const accessLogConfig = new tencentcloud.TcmAccessLogConfig("accessLogConfig", {
        address: "10.0.0.1",
        cls: {
            enable: false,
        },
        enable: true,
        enableServer: true,
        enableStdout: true,
        encoding: "JSON",
        format: `{
    \x09"authority": "%REQ(:AUTHORITY)%",
    \x09"bytes_received": "%BYTES_RECEIVED%",
    \x09"bytes_sent": "%BYTES_SENT%",
    \x09"downstream_local_address": "%DOWNSTREAM_LOCAL_ADDRESS%",
    \x09"downstream_remote_address": "%DOWNSTREAM_REMOTE_ADDRESS%",
    \x09"duration": "%DURATION%",
    \x09"istio_policy_status": "%DYNAMIC_METADATA(istio.mixer:status)%",
    \x09"method": "%REQ(:METHOD)%",
    \x09"path": "%REQ(X-ENVOY-ORIGINAL-PATH?:PATH)%",
    \x09"protocol": "%PROTOCOL%",
    \x09"request_id": "%REQ(X-REQUEST-ID)%",
    \x09"requested_server_name": "%REQUESTED_SERVER_NAME%",
    \x09"response_code": "%RESPONSE_CODE%",
    \x09"response_flags": "%RESPONSE_FLAGS%",
    \x09"route_name": "%ROUTE_NAME%",
    \x09"start_time": "%START_TIME%",
    \x09"upstream_cluster": "%UPSTREAM_CLUSTER%",
    \x09"upstream_host": "%UPSTREAM_HOST%",
    \x09"upstream_local_address": "%UPSTREAM_LOCAL_ADDRESS%",
    \x09"upstream_service_time": "%RESP(X-ENVOY-UPSTREAM-SERVICE-TIME)%",
    \x09"upstream_transport_failure_reason": "%UPSTREAM_TRANSPORT_FAILURE_REASON%",
    \x09"user_agent": "%REQ(USER-AGENT)%",
    \x09"x_forwarded_for": "%REQ(X-FORWARDED-FOR)%"
    }
    
    `,
        meshName: "mesh-rofjmxxx",
        selectedRange: {
            all: true,
        },
        template: "istio",
    });
    const deleteLogConfig = new tencentcloud.TcmAccessLogConfig("deleteLogConfig", {
        cls: {
            enable: false,
        },
        enableServer: false,
        enableStdout: false,
        meshName: "mesh-rofjmux7",
    });
    
    import pulumi
    import pulumi_tencentcloud as tencentcloud
    
    access_log_config = tencentcloud.TcmAccessLogConfig("accessLogConfig",
        address="10.0.0.1",
        cls={
            "enable": False,
        },
        enable=True,
        enable_server=True,
        enable_stdout=True,
        encoding="JSON",
        format="""{
    \x09"authority": "%REQ(:AUTHORITY)%",
    \x09"bytes_received": "%BYTES_RECEIVED%",
    \x09"bytes_sent": "%BYTES_SENT%",
    \x09"downstream_local_address": "%DOWNSTREAM_LOCAL_ADDRESS%",
    \x09"downstream_remote_address": "%DOWNSTREAM_REMOTE_ADDRESS%",
    \x09"duration": "%DURATION%",
    \x09"istio_policy_status": "%DYNAMIC_METADATA(istio.mixer:status)%",
    \x09"method": "%REQ(:METHOD)%",
    \x09"path": "%REQ(X-ENVOY-ORIGINAL-PATH?:PATH)%",
    \x09"protocol": "%PROTOCOL%",
    \x09"request_id": "%REQ(X-REQUEST-ID)%",
    \x09"requested_server_name": "%REQUESTED_SERVER_NAME%",
    \x09"response_code": "%RESPONSE_CODE%",
    \x09"response_flags": "%RESPONSE_FLAGS%",
    \x09"route_name": "%ROUTE_NAME%",
    \x09"start_time": "%START_TIME%",
    \x09"upstream_cluster": "%UPSTREAM_CLUSTER%",
    \x09"upstream_host": "%UPSTREAM_HOST%",
    \x09"upstream_local_address": "%UPSTREAM_LOCAL_ADDRESS%",
    \x09"upstream_service_time": "%RESP(X-ENVOY-UPSTREAM-SERVICE-TIME)%",
    \x09"upstream_transport_failure_reason": "%UPSTREAM_TRANSPORT_FAILURE_REASON%",
    \x09"user_agent": "%REQ(USER-AGENT)%",
    \x09"x_forwarded_for": "%REQ(X-FORWARDED-FOR)%"
    }
    
    """,
        mesh_name="mesh-rofjmxxx",
        selected_range={
            "all": True,
        },
        template="istio")
    delete_log_config = tencentcloud.TcmAccessLogConfig("deleteLogConfig",
        cls={
            "enable": False,
        },
        enable_server=False,
        enable_stdout=False,
        mesh_name="mesh-rofjmux7")
    
    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.NewTcmAccessLogConfig(ctx, "accessLogConfig", &tencentcloud.TcmAccessLogConfigArgs{
    			Address: pulumi.String("10.0.0.1"),
    			Cls: &tencentcloud.TcmAccessLogConfigClsArgs{
    				Enable: pulumi.Bool(false),
    			},
    			Enable:       pulumi.Bool(true),
    			EnableServer: pulumi.Bool(true),
    			EnableStdout: pulumi.Bool(true),
    			Encoding:     pulumi.String("JSON"),
    			Format: pulumi.String(`{
    	"authority": "%REQ(:AUTHORITY)%",
    	"bytes_received": "%BYTES_RECEIVED%",
    	"bytes_sent": "%BYTES_SENT%",
    	"downstream_local_address": "%DOWNSTREAM_LOCAL_ADDRESS%",
    	"downstream_remote_address": "%DOWNSTREAM_REMOTE_ADDRESS%",
    	"duration": "%DURATION%",
    	"istio_policy_status": "%DYNAMIC_METADATA(istio.mixer:status)%",
    	"method": "%REQ(:METHOD)%",
    	"path": "%REQ(X-ENVOY-ORIGINAL-PATH?:PATH)%",
    	"protocol": "%PROTOCOL%",
    	"request_id": "%REQ(X-REQUEST-ID)%",
    	"requested_server_name": "%REQUESTED_SERVER_NAME%",
    	"response_code": "%RESPONSE_CODE%",
    	"response_flags": "%RESPONSE_FLAGS%",
    	"route_name": "%ROUTE_NAME%",
    	"start_time": "%START_TIME%",
    	"upstream_cluster": "%UPSTREAM_CLUSTER%",
    	"upstream_host": "%UPSTREAM_HOST%",
    	"upstream_local_address": "%UPSTREAM_LOCAL_ADDRESS%",
    	"upstream_service_time": "%RESP(X-ENVOY-UPSTREAM-SERVICE-TIME)%",
    	"upstream_transport_failure_reason": "%UPSTREAM_TRANSPORT_FAILURE_REASON%",
    	"user_agent": "%REQ(USER-AGENT)%",
    	"x_forwarded_for": "%REQ(X-FORWARDED-FOR)%"
    }
    
    `),
    			MeshName: pulumi.String("mesh-rofjmxxx"),
    			SelectedRange: &tencentcloud.TcmAccessLogConfigSelectedRangeArgs{
    				All: pulumi.Bool(true),
    			},
    			Template: pulumi.String("istio"),
    		})
    		if err != nil {
    			return err
    		}
    		_, err = tencentcloud.NewTcmAccessLogConfig(ctx, "deleteLogConfig", &tencentcloud.TcmAccessLogConfigArgs{
    			Cls: &tencentcloud.TcmAccessLogConfigClsArgs{
    				Enable: pulumi.Bool(false),
    			},
    			EnableServer: pulumi.Bool(false),
    			EnableStdout: pulumi.Bool(false),
    			MeshName:     pulumi.String("mesh-rofjmux7"),
    		})
    		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 accessLogConfig = new Tencentcloud.TcmAccessLogConfig("accessLogConfig", new()
        {
            Address = "10.0.0.1",
            Cls = new Tencentcloud.Inputs.TcmAccessLogConfigClsArgs
            {
                Enable = false,
            },
            Enable = true,
            EnableServer = true,
            EnableStdout = true,
            Encoding = "JSON",
            Format = @"{
    	""authority"": ""%REQ(:AUTHORITY)%"",
    	""bytes_received"": ""%BYTES_RECEIVED%"",
    	""bytes_sent"": ""%BYTES_SENT%"",
    	""downstream_local_address"": ""%DOWNSTREAM_LOCAL_ADDRESS%"",
    	""downstream_remote_address"": ""%DOWNSTREAM_REMOTE_ADDRESS%"",
    	""duration"": ""%DURATION%"",
    	""istio_policy_status"": ""%DYNAMIC_METADATA(istio.mixer:status)%"",
    	""method"": ""%REQ(:METHOD)%"",
    	""path"": ""%REQ(X-ENVOY-ORIGINAL-PATH?:PATH)%"",
    	""protocol"": ""%PROTOCOL%"",
    	""request_id"": ""%REQ(X-REQUEST-ID)%"",
    	""requested_server_name"": ""%REQUESTED_SERVER_NAME%"",
    	""response_code"": ""%RESPONSE_CODE%"",
    	""response_flags"": ""%RESPONSE_FLAGS%"",
    	""route_name"": ""%ROUTE_NAME%"",
    	""start_time"": ""%START_TIME%"",
    	""upstream_cluster"": ""%UPSTREAM_CLUSTER%"",
    	""upstream_host"": ""%UPSTREAM_HOST%"",
    	""upstream_local_address"": ""%UPSTREAM_LOCAL_ADDRESS%"",
    	""upstream_service_time"": ""%RESP(X-ENVOY-UPSTREAM-SERVICE-TIME)%"",
    	""upstream_transport_failure_reason"": ""%UPSTREAM_TRANSPORT_FAILURE_REASON%"",
    	""user_agent"": ""%REQ(USER-AGENT)%"",
    	""x_forwarded_for"": ""%REQ(X-FORWARDED-FOR)%""
    }
    
    ",
            MeshName = "mesh-rofjmxxx",
            SelectedRange = new Tencentcloud.Inputs.TcmAccessLogConfigSelectedRangeArgs
            {
                All = true,
            },
            Template = "istio",
        });
    
        var deleteLogConfig = new Tencentcloud.TcmAccessLogConfig("deleteLogConfig", new()
        {
            Cls = new Tencentcloud.Inputs.TcmAccessLogConfigClsArgs
            {
                Enable = false,
            },
            EnableServer = false,
            EnableStdout = false,
            MeshName = "mesh-rofjmux7",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.tencentcloud.TcmAccessLogConfig;
    import com.pulumi.tencentcloud.TcmAccessLogConfigArgs;
    import com.pulumi.tencentcloud.inputs.TcmAccessLogConfigClsArgs;
    import com.pulumi.tencentcloud.inputs.TcmAccessLogConfigSelectedRangeArgs;
    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 accessLogConfig = new TcmAccessLogConfig("accessLogConfig", TcmAccessLogConfigArgs.builder()
                .address("10.0.0.1")
                .cls(TcmAccessLogConfigClsArgs.builder()
                    .enable(false)
                    .build())
                .enable(true)
                .enableServer(true)
                .enableStdout(true)
                .encoding("JSON")
                .format("""
    {
    	"authority": "%REQ(:AUTHORITY)%",
    	"bytes_received": "%BYTES_RECEIVED%",
    	"bytes_sent": "%BYTES_SENT%",
    	"downstream_local_address": "%DOWNSTREAM_LOCAL_ADDRESS%",
    	"downstream_remote_address": "%DOWNSTREAM_REMOTE_ADDRESS%",
    	"duration": "%DURATION%",
    	"istio_policy_status": "%DYNAMIC_METADATA(istio.mixer:status)%",
    	"method": "%REQ(:METHOD)%",
    	"path": "%REQ(X-ENVOY-ORIGINAL-PATH?:PATH)%",
    	"protocol": "%PROTOCOL%",
    	"request_id": "%REQ(X-REQUEST-ID)%",
    	"requested_server_name": "%REQUESTED_SERVER_NAME%",
    	"response_code": "%RESPONSE_CODE%",
    	"response_flags": "%RESPONSE_FLAGS%",
    	"route_name": "%ROUTE_NAME%",
    	"start_time": "%START_TIME%",
    	"upstream_cluster": "%UPSTREAM_CLUSTER%",
    	"upstream_host": "%UPSTREAM_HOST%",
    	"upstream_local_address": "%UPSTREAM_LOCAL_ADDRESS%",
    	"upstream_service_time": "%RESP(X-ENVOY-UPSTREAM-SERVICE-TIME)%",
    	"upstream_transport_failure_reason": "%UPSTREAM_TRANSPORT_FAILURE_REASON%",
    	"user_agent": "%REQ(USER-AGENT)%",
    	"x_forwarded_for": "%REQ(X-FORWARDED-FOR)%"
    }
    
                """)
                .meshName("mesh-rofjmxxx")
                .selectedRange(TcmAccessLogConfigSelectedRangeArgs.builder()
                    .all(true)
                    .build())
                .template("istio")
                .build());
    
            var deleteLogConfig = new TcmAccessLogConfig("deleteLogConfig", TcmAccessLogConfigArgs.builder()
                .cls(TcmAccessLogConfigClsArgs.builder()
                    .enable(false)
                    .build())
                .enableServer(false)
                .enableStdout(false)
                .meshName("mesh-rofjmux7")
                .build());
    
        }
    }
    
    resources:
      accessLogConfig:
        type: tencentcloud:TcmAccessLogConfig
        properties:
          address: 10.0.0.1
          cls:
            enable: false
          enable: true
          enableServer: true
          enableStdout: true
          encoding: JSON
          format: |+
            {
            	"authority": "%REQ(:AUTHORITY)%",
            	"bytes_received": "%BYTES_RECEIVED%",
            	"bytes_sent": "%BYTES_SENT%",
            	"downstream_local_address": "%DOWNSTREAM_LOCAL_ADDRESS%",
            	"downstream_remote_address": "%DOWNSTREAM_REMOTE_ADDRESS%",
            	"duration": "%DURATION%",
            	"istio_policy_status": "%DYNAMIC_METADATA(istio.mixer:status)%",
            	"method": "%REQ(:METHOD)%",
            	"path": "%REQ(X-ENVOY-ORIGINAL-PATH?:PATH)%",
            	"protocol": "%PROTOCOL%",
            	"request_id": "%REQ(X-REQUEST-ID)%",
            	"requested_server_name": "%REQUESTED_SERVER_NAME%",
            	"response_code": "%RESPONSE_CODE%",
            	"response_flags": "%RESPONSE_FLAGS%",
            	"route_name": "%ROUTE_NAME%",
            	"start_time": "%START_TIME%",
            	"upstream_cluster": "%UPSTREAM_CLUSTER%",
            	"upstream_host": "%UPSTREAM_HOST%",
            	"upstream_local_address": "%UPSTREAM_LOCAL_ADDRESS%",
            	"upstream_service_time": "%RESP(X-ENVOY-UPSTREAM-SERVICE-TIME)%",
            	"upstream_transport_failure_reason": "%UPSTREAM_TRANSPORT_FAILURE_REASON%",
            	"user_agent": "%REQ(USER-AGENT)%",
            	"x_forwarded_for": "%REQ(X-FORWARDED-FOR)%"
            }        
    
          meshName: mesh-rofjmxxx
          selectedRange:
            all: true
          template: istio
      deleteLogConfig:
        type: tencentcloud:TcmAccessLogConfig
        properties:
          cls:
            enable: false
          enableServer: false
          enableStdout: false
          meshName: mesh-rofjmux7
    

    Create TcmAccessLogConfig Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new TcmAccessLogConfig(name: string, args: TcmAccessLogConfigArgs, opts?: CustomResourceOptions);
    @overload
    def TcmAccessLogConfig(resource_name: str,
                           args: TcmAccessLogConfigArgs,
                           opts: Optional[ResourceOptions] = None)
    
    @overload
    def TcmAccessLogConfig(resource_name: str,
                           opts: Optional[ResourceOptions] = None,
                           mesh_name: Optional[str] = None,
                           address: Optional[str] = None,
                           cls: Optional[TcmAccessLogConfigClsArgs] = None,
                           enable: Optional[bool] = None,
                           enable_server: Optional[bool] = None,
                           enable_stdout: Optional[bool] = None,
                           encoding: Optional[str] = None,
                           format: Optional[str] = None,
                           selected_range: Optional[TcmAccessLogConfigSelectedRangeArgs] = None,
                           tcm_access_log_config_id: Optional[str] = None,
                           template: Optional[str] = None)
    func NewTcmAccessLogConfig(ctx *Context, name string, args TcmAccessLogConfigArgs, opts ...ResourceOption) (*TcmAccessLogConfig, error)
    public TcmAccessLogConfig(string name, TcmAccessLogConfigArgs args, CustomResourceOptions? opts = null)
    public TcmAccessLogConfig(String name, TcmAccessLogConfigArgs args)
    public TcmAccessLogConfig(String name, TcmAccessLogConfigArgs args, CustomResourceOptions options)
    
    type: tencentcloud:TcmAccessLogConfig
    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 TcmAccessLogConfigArgs
    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 TcmAccessLogConfigArgs
    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 TcmAccessLogConfigArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args TcmAccessLogConfigArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args TcmAccessLogConfigArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    TcmAccessLogConfig 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 TcmAccessLogConfig resource accepts the following input properties:

    MeshName string
    Mesh ID.
    Address string
    Third party grpc server address.
    Cls TcmAccessLogConfigCls
    CLS config.
    Enable bool
    Whether enable log.
    EnableServer bool
    Whether enable third party grpc server.
    EnableStdout bool
    Whether enable stdout.
    Encoding string
    Log encoding, TEXT or JSON.
    Format string
    Log format.
    SelectedRange TcmAccessLogConfigSelectedRange
    Selected range.
    TcmAccessLogConfigId string
    ID of the resource.
    Template string
    Log template, istio/trace/custome.
    MeshName string
    Mesh ID.
    Address string
    Third party grpc server address.
    Cls TcmAccessLogConfigClsArgs
    CLS config.
    Enable bool
    Whether enable log.
    EnableServer bool
    Whether enable third party grpc server.
    EnableStdout bool
    Whether enable stdout.
    Encoding string
    Log encoding, TEXT or JSON.
    Format string
    Log format.
    SelectedRange TcmAccessLogConfigSelectedRangeArgs
    Selected range.
    TcmAccessLogConfigId string
    ID of the resource.
    Template string
    Log template, istio/trace/custome.
    meshName String
    Mesh ID.
    address String
    Third party grpc server address.
    cls TcmAccessLogConfigCls
    CLS config.
    enable Boolean
    Whether enable log.
    enableServer Boolean
    Whether enable third party grpc server.
    enableStdout Boolean
    Whether enable stdout.
    encoding String
    Log encoding, TEXT or JSON.
    format String
    Log format.
    selectedRange TcmAccessLogConfigSelectedRange
    Selected range.
    tcmAccessLogConfigId String
    ID of the resource.
    template String
    Log template, istio/trace/custome.
    meshName string
    Mesh ID.
    address string
    Third party grpc server address.
    cls TcmAccessLogConfigCls
    CLS config.
    enable boolean
    Whether enable log.
    enableServer boolean
    Whether enable third party grpc server.
    enableStdout boolean
    Whether enable stdout.
    encoding string
    Log encoding, TEXT or JSON.
    format string
    Log format.
    selectedRange TcmAccessLogConfigSelectedRange
    Selected range.
    tcmAccessLogConfigId string
    ID of the resource.
    template string
    Log template, istio/trace/custome.
    mesh_name str
    Mesh ID.
    address str
    Third party grpc server address.
    cls TcmAccessLogConfigClsArgs
    CLS config.
    enable bool
    Whether enable log.
    enable_server bool
    Whether enable third party grpc server.
    enable_stdout bool
    Whether enable stdout.
    encoding str
    Log encoding, TEXT or JSON.
    format str
    Log format.
    selected_range TcmAccessLogConfigSelectedRangeArgs
    Selected range.
    tcm_access_log_config_id str
    ID of the resource.
    template str
    Log template, istio/trace/custome.
    meshName String
    Mesh ID.
    address String
    Third party grpc server address.
    cls Property Map
    CLS config.
    enable Boolean
    Whether enable log.
    enableServer Boolean
    Whether enable third party grpc server.
    enableStdout Boolean
    Whether enable stdout.
    encoding String
    Log encoding, TEXT or JSON.
    format String
    Log format.
    selectedRange Property Map
    Selected range.
    tcmAccessLogConfigId String
    ID of the resource.
    template String
    Log template, istio/trace/custome.

    Outputs

    All input properties are implicitly available as output properties. Additionally, the TcmAccessLogConfig 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 TcmAccessLogConfig Resource

    Get an existing TcmAccessLogConfig 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?: TcmAccessLogConfigState, opts?: CustomResourceOptions): TcmAccessLogConfig
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            address: Optional[str] = None,
            cls: Optional[TcmAccessLogConfigClsArgs] = None,
            enable: Optional[bool] = None,
            enable_server: Optional[bool] = None,
            enable_stdout: Optional[bool] = None,
            encoding: Optional[str] = None,
            format: Optional[str] = None,
            mesh_name: Optional[str] = None,
            selected_range: Optional[TcmAccessLogConfigSelectedRangeArgs] = None,
            tcm_access_log_config_id: Optional[str] = None,
            template: Optional[str] = None) -> TcmAccessLogConfig
    func GetTcmAccessLogConfig(ctx *Context, name string, id IDInput, state *TcmAccessLogConfigState, opts ...ResourceOption) (*TcmAccessLogConfig, error)
    public static TcmAccessLogConfig Get(string name, Input<string> id, TcmAccessLogConfigState? state, CustomResourceOptions? opts = null)
    public static TcmAccessLogConfig get(String name, Output<String> id, TcmAccessLogConfigState state, CustomResourceOptions options)
    resources:  _:    type: tencentcloud:TcmAccessLogConfig    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.
    The following state arguments are supported:
    Address string
    Third party grpc server address.
    Cls TcmAccessLogConfigCls
    CLS config.
    Enable bool
    Whether enable log.
    EnableServer bool
    Whether enable third party grpc server.
    EnableStdout bool
    Whether enable stdout.
    Encoding string
    Log encoding, TEXT or JSON.
    Format string
    Log format.
    MeshName string
    Mesh ID.
    SelectedRange TcmAccessLogConfigSelectedRange
    Selected range.
    TcmAccessLogConfigId string
    ID of the resource.
    Template string
    Log template, istio/trace/custome.
    Address string
    Third party grpc server address.
    Cls TcmAccessLogConfigClsArgs
    CLS config.
    Enable bool
    Whether enable log.
    EnableServer bool
    Whether enable third party grpc server.
    EnableStdout bool
    Whether enable stdout.
    Encoding string
    Log encoding, TEXT or JSON.
    Format string
    Log format.
    MeshName string
    Mesh ID.
    SelectedRange TcmAccessLogConfigSelectedRangeArgs
    Selected range.
    TcmAccessLogConfigId string
    ID of the resource.
    Template string
    Log template, istio/trace/custome.
    address String
    Third party grpc server address.
    cls TcmAccessLogConfigCls
    CLS config.
    enable Boolean
    Whether enable log.
    enableServer Boolean
    Whether enable third party grpc server.
    enableStdout Boolean
    Whether enable stdout.
    encoding String
    Log encoding, TEXT or JSON.
    format String
    Log format.
    meshName String
    Mesh ID.
    selectedRange TcmAccessLogConfigSelectedRange
    Selected range.
    tcmAccessLogConfigId String
    ID of the resource.
    template String
    Log template, istio/trace/custome.
    address string
    Third party grpc server address.
    cls TcmAccessLogConfigCls
    CLS config.
    enable boolean
    Whether enable log.
    enableServer boolean
    Whether enable third party grpc server.
    enableStdout boolean
    Whether enable stdout.
    encoding string
    Log encoding, TEXT or JSON.
    format string
    Log format.
    meshName string
    Mesh ID.
    selectedRange TcmAccessLogConfigSelectedRange
    Selected range.
    tcmAccessLogConfigId string
    ID of the resource.
    template string
    Log template, istio/trace/custome.
    address str
    Third party grpc server address.
    cls TcmAccessLogConfigClsArgs
    CLS config.
    enable bool
    Whether enable log.
    enable_server bool
    Whether enable third party grpc server.
    enable_stdout bool
    Whether enable stdout.
    encoding str
    Log encoding, TEXT or JSON.
    format str
    Log format.
    mesh_name str
    Mesh ID.
    selected_range TcmAccessLogConfigSelectedRangeArgs
    Selected range.
    tcm_access_log_config_id str
    ID of the resource.
    template str
    Log template, istio/trace/custome.
    address String
    Third party grpc server address.
    cls Property Map
    CLS config.
    enable Boolean
    Whether enable log.
    enableServer Boolean
    Whether enable third party grpc server.
    enableStdout Boolean
    Whether enable stdout.
    encoding String
    Log encoding, TEXT or JSON.
    format String
    Log format.
    meshName String
    Mesh ID.
    selectedRange Property Map
    Selected range.
    tcmAccessLogConfigId String
    ID of the resource.
    template String
    Log template, istio/trace/custome.

    Supporting Types

    TcmAccessLogConfigCls, TcmAccessLogConfigClsArgs

    Enable bool
    Whether enable CLS.
    LogSet string
    Log set of CLS.
    Topic string
    Log topic of CLS.
    Enable bool
    Whether enable CLS.
    LogSet string
    Log set of CLS.
    Topic string
    Log topic of CLS.
    enable Boolean
    Whether enable CLS.
    logSet String
    Log set of CLS.
    topic String
    Log topic of CLS.
    enable boolean
    Whether enable CLS.
    logSet string
    Log set of CLS.
    topic string
    Log topic of CLS.
    enable bool
    Whether enable CLS.
    log_set str
    Log set of CLS.
    topic str
    Log topic of CLS.
    enable Boolean
    Whether enable CLS.
    logSet String
    Log set of CLS.
    topic String
    Log topic of CLS.

    TcmAccessLogConfigSelectedRange, TcmAccessLogConfigSelectedRangeArgs

    All bool
    Select all if true, default false.
    Items List<TcmAccessLogConfigSelectedRangeItem>
    Items.
    All bool
    Select all if true, default false.
    Items []TcmAccessLogConfigSelectedRangeItem
    Items.
    all Boolean
    Select all if true, default false.
    items List<TcmAccessLogConfigSelectedRangeItem>
    Items.
    all boolean
    Select all if true, default false.
    items TcmAccessLogConfigSelectedRangeItem[]
    Items.
    all bool
    Select all if true, default false.
    items Sequence[TcmAccessLogConfigSelectedRangeItem]
    Items.
    all Boolean
    Select all if true, default false.
    items List<Property Map>
    Items.

    TcmAccessLogConfigSelectedRangeItem, TcmAccessLogConfigSelectedRangeItemArgs

    Gateways List<string>
    Ingress gateway list.
    Namespace string
    Namespace.
    Gateways []string
    Ingress gateway list.
    Namespace string
    Namespace.
    gateways List<String>
    Ingress gateway list.
    namespace String
    Namespace.
    gateways string[]
    Ingress gateway list.
    namespace string
    Namespace.
    gateways Sequence[str]
    Ingress gateway list.
    namespace str
    Namespace.
    gateways List<String>
    Ingress gateway list.
    namespace String
    Namespace.

    Import

    tcm access_log_config can be imported using the mesh_id(mesh_name), e.g.

    $ pulumi import tencentcloud:index/tcmAccessLogConfig:TcmAccessLogConfig access_log_config mesh-rofjmxxx
    

    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.
    tencentcloud logo
    tencentcloud 1.81.189 published on Wednesday, Apr 30, 2025 by tencentcloudstack