1. Packages
  2. AWS Classic
  3. API Docs
  4. securitylake
  5. AwsLogSource

Try AWS Native preview for resources not in the classic version.

AWS Classic v6.42.0 published on Wednesday, Jun 26, 2024 by Pulumi

aws.securitylake.AwsLogSource

Explore with Pulumi AI

aws logo

Try AWS Native preview for resources not in the classic version.

AWS Classic v6.42.0 published on Wednesday, Jun 26, 2024 by Pulumi

    Resource for managing an Amazon Security Lake AWS Log Source.

    NOTE: A single aws.securitylake.AwsLogSource should be used to configure a log source across all regions and accounts.

    NOTE: The underlying aws.securitylake.DataLake must be configured before creating the aws.securitylake.AwsLogSource. Use a depends_on statement.

    Example Usage

    Basic Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as aws from "@pulumi/aws";
    
    const example = new aws.securitylake.AwsLogSource("example", {source: {
        accounts: ["123456789012"],
        regions: ["eu-west-1"],
        sourceName: "ROUTE53",
    }}, {
        dependsOn: [exampleAwsSecuritylakeDataLake],
    });
    
    import pulumi
    import pulumi_aws as aws
    
    example = aws.securitylake.AwsLogSource("example", source={
        "accounts": ["123456789012"],
        "regions": ["eu-west-1"],
        "sourceName": "ROUTE53",
    },
    opts = pulumi.ResourceOptions(depends_on=[example_aws_securitylake_data_lake]))
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/securitylake"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := securitylake.NewAwsLogSource(ctx, "example", &securitylake.AwsLogSourceArgs{
    			Source: &securitylake.AwsLogSourceSourceArgs{
    				Accounts: pulumi.StringArray{
    					pulumi.String("123456789012"),
    				},
    				Regions: pulumi.StringArray{
    					pulumi.String("eu-west-1"),
    				},
    				SourceName: pulumi.String("ROUTE53"),
    			},
    		}, pulumi.DependsOn([]pulumi.Resource{
    			exampleAwsSecuritylakeDataLake,
    		}))
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Aws = Pulumi.Aws;
    
    return await Deployment.RunAsync(() => 
    {
        var example = new Aws.SecurityLake.AwsLogSource("example", new()
        {
            Source = new Aws.SecurityLake.Inputs.AwsLogSourceSourceArgs
            {
                Accounts = new[]
                {
                    "123456789012",
                },
                Regions = new[]
                {
                    "eu-west-1",
                },
                SourceName = "ROUTE53",
            },
        }, new CustomResourceOptions
        {
            DependsOn =
            {
                exampleAwsSecuritylakeDataLake,
            },
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.aws.securitylake.AwsLogSource;
    import com.pulumi.aws.securitylake.AwsLogSourceArgs;
    import com.pulumi.aws.securitylake.inputs.AwsLogSourceSourceArgs;
    import com.pulumi.resources.CustomResourceOptions;
    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 AwsLogSource("example", AwsLogSourceArgs.builder()
                .source(AwsLogSourceSourceArgs.builder()
                    .accounts("123456789012")
                    .regions("eu-west-1")
                    .sourceName("ROUTE53")
                    .build())
                .build(), CustomResourceOptions.builder()
                    .dependsOn(exampleAwsSecuritylakeDataLake)
                    .build());
    
        }
    }
    
    resources:
      example:
        type: aws:securitylake:AwsLogSource
        properties:
          source:
            accounts:
              - '123456789012'
            regions:
              - eu-west-1
            sourceName: ROUTE53
        options:
          dependson:
            - ${exampleAwsSecuritylakeDataLake}
    

    Create AwsLogSource Resource

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

    Constructor syntax

    new AwsLogSource(name: string, args?: AwsLogSourceArgs, opts?: CustomResourceOptions);
    @overload
    def AwsLogSource(resource_name: str,
                     args: Optional[AwsLogSourceArgs] = None,
                     opts: Optional[ResourceOptions] = None)
    
    @overload
    def AwsLogSource(resource_name: str,
                     opts: Optional[ResourceOptions] = None,
                     source: Optional[AwsLogSourceSourceArgs] = None)
    func NewAwsLogSource(ctx *Context, name string, args *AwsLogSourceArgs, opts ...ResourceOption) (*AwsLogSource, error)
    public AwsLogSource(string name, AwsLogSourceArgs? args = null, CustomResourceOptions? opts = null)
    public AwsLogSource(String name, AwsLogSourceArgs args)
    public AwsLogSource(String name, AwsLogSourceArgs args, CustomResourceOptions options)
    
    type: aws:securitylake:AwsLogSource
    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 AwsLogSourceArgs
    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 AwsLogSourceArgs
    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 AwsLogSourceArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args AwsLogSourceArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args AwsLogSourceArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Constructor example

    The following reference example uses placeholder values for all input properties.

    var awsLogSourceResource = new Aws.SecurityLake.AwsLogSource("awsLogSourceResource", new()
    {
        Source = new Aws.SecurityLake.Inputs.AwsLogSourceSourceArgs
        {
            Regions = new[]
            {
                "string",
            },
            SourceName = "string",
            Accounts = new[]
            {
                "string",
            },
            SourceVersion = "string",
        },
    });
    
    example, err := securitylake.NewAwsLogSource(ctx, "awsLogSourceResource", &securitylake.AwsLogSourceArgs{
    	Source: &securitylake.AwsLogSourceSourceArgs{
    		Regions: pulumi.StringArray{
    			pulumi.String("string"),
    		},
    		SourceName: pulumi.String("string"),
    		Accounts: pulumi.StringArray{
    			pulumi.String("string"),
    		},
    		SourceVersion: pulumi.String("string"),
    	},
    })
    
    var awsLogSourceResource = new AwsLogSource("awsLogSourceResource", AwsLogSourceArgs.builder()
        .source(AwsLogSourceSourceArgs.builder()
            .regions("string")
            .sourceName("string")
            .accounts("string")
            .sourceVersion("string")
            .build())
        .build());
    
    aws_log_source_resource = aws.securitylake.AwsLogSource("awsLogSourceResource", source={
        "regions": ["string"],
        "sourceName": "string",
        "accounts": ["string"],
        "sourceVersion": "string",
    })
    
    const awsLogSourceResource = new aws.securitylake.AwsLogSource("awsLogSourceResource", {source: {
        regions: ["string"],
        sourceName: "string",
        accounts: ["string"],
        sourceVersion: "string",
    }});
    
    type: aws:securitylake:AwsLogSource
    properties:
        source:
            accounts:
                - string
            regions:
                - string
            sourceName: string
            sourceVersion: string
    

    AwsLogSource Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    The AwsLogSource resource accepts the following input properties:

    Source AwsLogSourceSource
    Specify the natively-supported AWS service to add as a source in Security Lake.
    Source AwsLogSourceSourceArgs
    Specify the natively-supported AWS service to add as a source in Security Lake.
    source AwsLogSourceSource
    Specify the natively-supported AWS service to add as a source in Security Lake.
    source AwsLogSourceSource
    Specify the natively-supported AWS service to add as a source in Security Lake.
    source AwsLogSourceSourceArgs
    Specify the natively-supported AWS service to add as a source in Security Lake.
    source Property Map
    Specify the natively-supported AWS service to add as a source in Security Lake.

    Outputs

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

    Get an existing AwsLogSource 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?: AwsLogSourceState, opts?: CustomResourceOptions): AwsLogSource
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            source: Optional[AwsLogSourceSourceArgs] = None) -> AwsLogSource
    func GetAwsLogSource(ctx *Context, name string, id IDInput, state *AwsLogSourceState, opts ...ResourceOption) (*AwsLogSource, error)
    public static AwsLogSource Get(string name, Input<string> id, AwsLogSourceState? state, CustomResourceOptions? opts = null)
    public static AwsLogSource get(String name, Output<String> id, AwsLogSourceState state, CustomResourceOptions options)
    Resource lookup is not supported in YAML
    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:
    Source AwsLogSourceSource
    Specify the natively-supported AWS service to add as a source in Security Lake.
    Source AwsLogSourceSourceArgs
    Specify the natively-supported AWS service to add as a source in Security Lake.
    source AwsLogSourceSource
    Specify the natively-supported AWS service to add as a source in Security Lake.
    source AwsLogSourceSource
    Specify the natively-supported AWS service to add as a source in Security Lake.
    source AwsLogSourceSourceArgs
    Specify the natively-supported AWS service to add as a source in Security Lake.
    source Property Map
    Specify the natively-supported AWS service to add as a source in Security Lake.

    Supporting Types

    AwsLogSourceSource, AwsLogSourceSourceArgs

    Regions List<string>
    Specify the Regions where you want to enable Security Lake.
    SourceName string
    The name for a AWS source. This must be a Regionally unique value. Valid values: ROUTE53, VPC_FLOW, SH_FINDINGS, CLOUD_TRAIL_MGMT, LAMBDA_EXECUTION, S3_DATA.
    Accounts List<string>
    Specify the AWS account information where you want to enable Security Lake. If not specified, uses all accounts included in the Security Lake.
    SourceVersion string
    The version for a AWS source. If not specified, the version will be the default. This must be a Regionally unique value.
    Regions []string
    Specify the Regions where you want to enable Security Lake.
    SourceName string
    The name for a AWS source. This must be a Regionally unique value. Valid values: ROUTE53, VPC_FLOW, SH_FINDINGS, CLOUD_TRAIL_MGMT, LAMBDA_EXECUTION, S3_DATA.
    Accounts []string
    Specify the AWS account information where you want to enable Security Lake. If not specified, uses all accounts included in the Security Lake.
    SourceVersion string
    The version for a AWS source. If not specified, the version will be the default. This must be a Regionally unique value.
    regions List<String>
    Specify the Regions where you want to enable Security Lake.
    sourceName String
    The name for a AWS source. This must be a Regionally unique value. Valid values: ROUTE53, VPC_FLOW, SH_FINDINGS, CLOUD_TRAIL_MGMT, LAMBDA_EXECUTION, S3_DATA.
    accounts List<String>
    Specify the AWS account information where you want to enable Security Lake. If not specified, uses all accounts included in the Security Lake.
    sourceVersion String
    The version for a AWS source. If not specified, the version will be the default. This must be a Regionally unique value.
    regions string[]
    Specify the Regions where you want to enable Security Lake.
    sourceName string
    The name for a AWS source. This must be a Regionally unique value. Valid values: ROUTE53, VPC_FLOW, SH_FINDINGS, CLOUD_TRAIL_MGMT, LAMBDA_EXECUTION, S3_DATA.
    accounts string[]
    Specify the AWS account information where you want to enable Security Lake. If not specified, uses all accounts included in the Security Lake.
    sourceVersion string
    The version for a AWS source. If not specified, the version will be the default. This must be a Regionally unique value.
    regions Sequence[str]
    Specify the Regions where you want to enable Security Lake.
    source_name str
    The name for a AWS source. This must be a Regionally unique value. Valid values: ROUTE53, VPC_FLOW, SH_FINDINGS, CLOUD_TRAIL_MGMT, LAMBDA_EXECUTION, S3_DATA.
    accounts Sequence[str]
    Specify the AWS account information where you want to enable Security Lake. If not specified, uses all accounts included in the Security Lake.
    source_version str
    The version for a AWS source. If not specified, the version will be the default. This must be a Regionally unique value.
    regions List<String>
    Specify the Regions where you want to enable Security Lake.
    sourceName String
    The name for a AWS source. This must be a Regionally unique value. Valid values: ROUTE53, VPC_FLOW, SH_FINDINGS, CLOUD_TRAIL_MGMT, LAMBDA_EXECUTION, S3_DATA.
    accounts List<String>
    Specify the AWS account information where you want to enable Security Lake. If not specified, uses all accounts included in the Security Lake.
    sourceVersion String
    The version for a AWS source. If not specified, the version will be the default. This must be a Regionally unique value.

    Import

    Using pulumi import, import AWS log sources using the source name. For example:

    $ pulumi import aws:securitylake/awsLogSource:AwsLogSource example ROUTE53
    

    To learn more about importing existing cloud resources, see Importing resources.

    Package Details

    Repository
    AWS Classic pulumi/pulumi-aws
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the aws Terraform Provider.
    aws logo

    Try AWS Native preview for resources not in the classic version.

    AWS Classic v6.42.0 published on Wednesday, Jun 26, 2024 by Pulumi