1. Packages
  2. AWS
  3. API Docs
  4. cloudfront
  5. getOriginAccessControl
AWS v6.60.0 published on Tuesday, Nov 19, 2024 by Pulumi

aws.cloudfront.getOriginAccessControl

Explore with Pulumi AI

aws logo
AWS v6.60.0 published on Tuesday, Nov 19, 2024 by Pulumi

    Use this data source to retrieve information for an Amazon CloudFront origin access control config.

    Example Usage

    The below example retrieves a CloudFront origin access control config.

    import * as pulumi from "@pulumi/pulumi";
    import * as aws from "@pulumi/aws";
    
    const example = aws.cloudfront.getOriginAccessControl({
        id: "E2T5VTFBZJ3BJB",
    });
    
    import pulumi
    import pulumi_aws as aws
    
    example = aws.cloudfront.get_origin_access_control(id="E2T5VTFBZJ3BJB")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/cloudfront"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := cloudfront.LookupOriginAccessControl(ctx, &cloudfront.LookupOriginAccessControlArgs{
    			Id: "E2T5VTFBZJ3BJB",
    		}, nil)
    		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 = Aws.CloudFront.GetOriginAccessControl.Invoke(new()
        {
            Id = "E2T5VTFBZJ3BJB",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.aws.cloudfront.CloudfrontFunctions;
    import com.pulumi.aws.cloudfront.inputs.GetOriginAccessControlArgs;
    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) {
            final var example = CloudfrontFunctions.getOriginAccessControl(GetOriginAccessControlArgs.builder()
                .id("E2T5VTFBZJ3BJB")
                .build());
    
        }
    }
    
    variables:
      example:
        fn::invoke:
          Function: aws:cloudfront:getOriginAccessControl
          Arguments:
            id: E2T5VTFBZJ3BJB
    

    Using getOriginAccessControl

    Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

    function getOriginAccessControl(args: GetOriginAccessControlArgs, opts?: InvokeOptions): Promise<GetOriginAccessControlResult>
    function getOriginAccessControlOutput(args: GetOriginAccessControlOutputArgs, opts?: InvokeOptions): Output<GetOriginAccessControlResult>
    def get_origin_access_control(id: Optional[str] = None,
                                  opts: Optional[InvokeOptions] = None) -> GetOriginAccessControlResult
    def get_origin_access_control_output(id: Optional[pulumi.Input[str]] = None,
                                  opts: Optional[InvokeOptions] = None) -> Output[GetOriginAccessControlResult]
    func LookupOriginAccessControl(ctx *Context, args *LookupOriginAccessControlArgs, opts ...InvokeOption) (*LookupOriginAccessControlResult, error)
    func LookupOriginAccessControlOutput(ctx *Context, args *LookupOriginAccessControlOutputArgs, opts ...InvokeOption) LookupOriginAccessControlResultOutput

    > Note: This function is named LookupOriginAccessControl in the Go SDK.

    public static class GetOriginAccessControl 
    {
        public static Task<GetOriginAccessControlResult> InvokeAsync(GetOriginAccessControlArgs args, InvokeOptions? opts = null)
        public static Output<GetOriginAccessControlResult> Invoke(GetOriginAccessControlInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetOriginAccessControlResult> getOriginAccessControl(GetOriginAccessControlArgs args, InvokeOptions options)
    // Output-based functions aren't available in Java yet
    
    fn::invoke:
      function: aws:cloudfront/getOriginAccessControl:getOriginAccessControl
      arguments:
        # arguments dictionary

    The following arguments are supported:

    Id string
    The identifier for the origin access control settings. For example: E2T5VTFBZJ3BJB.
    Id string
    The identifier for the origin access control settings. For example: E2T5VTFBZJ3BJB.
    id String
    The identifier for the origin access control settings. For example: E2T5VTFBZJ3BJB.
    id string
    The identifier for the origin access control settings. For example: E2T5VTFBZJ3BJB.
    id str
    The identifier for the origin access control settings. For example: E2T5VTFBZJ3BJB.
    id String
    The identifier for the origin access control settings. For example: E2T5VTFBZJ3BJB.

    getOriginAccessControl Result

    The following output properties are available:

    Description string
    A description of the origin access control.
    Etag string
    Current version of the origin access control's information. For example: E2QWRUHAPOMQZL.
    Id string
    Name string
    A name to identify the origin access control.
    OriginAccessControlOriginType string
    The type of origin that this origin access control is for.
    SigningBehavior string
    Specifies which requests CloudFront signs.
    SigningProtocol string
    The signing protocol of the origin access control, which determines how CloudFront signs (authenticates) requests.
    Description string
    A description of the origin access control.
    Etag string
    Current version of the origin access control's information. For example: E2QWRUHAPOMQZL.
    Id string
    Name string
    A name to identify the origin access control.
    OriginAccessControlOriginType string
    The type of origin that this origin access control is for.
    SigningBehavior string
    Specifies which requests CloudFront signs.
    SigningProtocol string
    The signing protocol of the origin access control, which determines how CloudFront signs (authenticates) requests.
    description String
    A description of the origin access control.
    etag String
    Current version of the origin access control's information. For example: E2QWRUHAPOMQZL.
    id String
    name String
    A name to identify the origin access control.
    originAccessControlOriginType String
    The type of origin that this origin access control is for.
    signingBehavior String
    Specifies which requests CloudFront signs.
    signingProtocol String
    The signing protocol of the origin access control, which determines how CloudFront signs (authenticates) requests.
    description string
    A description of the origin access control.
    etag string
    Current version of the origin access control's information. For example: E2QWRUHAPOMQZL.
    id string
    name string
    A name to identify the origin access control.
    originAccessControlOriginType string
    The type of origin that this origin access control is for.
    signingBehavior string
    Specifies which requests CloudFront signs.
    signingProtocol string
    The signing protocol of the origin access control, which determines how CloudFront signs (authenticates) requests.
    description str
    A description of the origin access control.
    etag str
    Current version of the origin access control's information. For example: E2QWRUHAPOMQZL.
    id str
    name str
    A name to identify the origin access control.
    origin_access_control_origin_type str
    The type of origin that this origin access control is for.
    signing_behavior str
    Specifies which requests CloudFront signs.
    signing_protocol str
    The signing protocol of the origin access control, which determines how CloudFront signs (authenticates) requests.
    description String
    A description of the origin access control.
    etag String
    Current version of the origin access control's information. For example: E2QWRUHAPOMQZL.
    id String
    name String
    A name to identify the origin access control.
    originAccessControlOriginType String
    The type of origin that this origin access control is for.
    signingBehavior String
    Specifies which requests CloudFront signs.
    signingProtocol String
    The signing protocol of the origin access control, which determines how CloudFront signs (authenticates) requests.

    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
    AWS v6.60.0 published on Tuesday, Nov 19, 2024 by Pulumi