1. Packages
  2. AWS Classic
  3. API Docs
  4. acmpca
  5. Permission

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

AWS Classic v5.41.0 published on Monday, May 15, 2023 by Pulumi

aws.acmpca.Permission

Explore with Pulumi AI

aws logo

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

AWS Classic v5.41.0 published on Monday, May 15, 2023 by Pulumi

    Provides a resource to manage an AWS Certificate Manager Private Certificate Authorities Permission. Currently, this is only required in order to allow the ACM service to automatically renew certificates issued by a PCA.

    Example Usage

    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Aws = Pulumi.Aws;
    
    return await Deployment.RunAsync(() => 
    {
        var exampleCertificateAuthority = new Aws.Acmpca.CertificateAuthority("exampleCertificateAuthority", new()
        {
            CertificateAuthorityConfiguration = new Aws.Acmpca.Inputs.CertificateAuthorityCertificateAuthorityConfigurationArgs
            {
                KeyAlgorithm = "RSA_4096",
                SigningAlgorithm = "SHA512WITHRSA",
                Subject = new Aws.Acmpca.Inputs.CertificateAuthorityCertificateAuthorityConfigurationSubjectArgs
                {
                    CommonName = "example.com",
                },
            },
        });
    
        var examplePermission = new Aws.Acmpca.Permission("examplePermission", new()
        {
            CertificateAuthorityArn = exampleCertificateAuthority.Arn,
            Actions = new[]
            {
                "IssueCertificate",
                "GetCertificate",
                "ListPermissions",
            },
            Principal = "acm.amazonaws.com",
        });
    
    });
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-aws/sdk/v5/go/aws/acmpca"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		exampleCertificateAuthority, err := acmpca.NewCertificateAuthority(ctx, "exampleCertificateAuthority", &acmpca.CertificateAuthorityArgs{
    			CertificateAuthorityConfiguration: &acmpca.CertificateAuthorityCertificateAuthorityConfigurationArgs{
    				KeyAlgorithm:     pulumi.String("RSA_4096"),
    				SigningAlgorithm: pulumi.String("SHA512WITHRSA"),
    				Subject: &acmpca.CertificateAuthorityCertificateAuthorityConfigurationSubjectArgs{
    					CommonName: pulumi.String("example.com"),
    				},
    			},
    		})
    		if err != nil {
    			return err
    		}
    		_, err = acmpca.NewPermission(ctx, "examplePermission", &acmpca.PermissionArgs{
    			CertificateAuthorityArn: exampleCertificateAuthority.Arn,
    			Actions: pulumi.StringArray{
    				pulumi.String("IssueCertificate"),
    				pulumi.String("GetCertificate"),
    				pulumi.String("ListPermissions"),
    			},
    			Principal: pulumi.String("acm.amazonaws.com"),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.aws.acmpca.CertificateAuthority;
    import com.pulumi.aws.acmpca.CertificateAuthorityArgs;
    import com.pulumi.aws.acmpca.inputs.CertificateAuthorityCertificateAuthorityConfigurationArgs;
    import com.pulumi.aws.acmpca.inputs.CertificateAuthorityCertificateAuthorityConfigurationSubjectArgs;
    import com.pulumi.aws.acmpca.Permission;
    import com.pulumi.aws.acmpca.PermissionArgs;
    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 exampleCertificateAuthority = new CertificateAuthority("exampleCertificateAuthority", CertificateAuthorityArgs.builder()        
                .certificateAuthorityConfiguration(CertificateAuthorityCertificateAuthorityConfigurationArgs.builder()
                    .keyAlgorithm("RSA_4096")
                    .signingAlgorithm("SHA512WITHRSA")
                    .subject(CertificateAuthorityCertificateAuthorityConfigurationSubjectArgs.builder()
                        .commonName("example.com")
                        .build())
                    .build())
                .build());
    
            var examplePermission = new Permission("examplePermission", PermissionArgs.builder()        
                .certificateAuthorityArn(exampleCertificateAuthority.arn())
                .actions(            
                    "IssueCertificate",
                    "GetCertificate",
                    "ListPermissions")
                .principal("acm.amazonaws.com")
                .build());
    
        }
    }
    
    import pulumi
    import pulumi_aws as aws
    
    example_certificate_authority = aws.acmpca.CertificateAuthority("exampleCertificateAuthority", certificate_authority_configuration=aws.acmpca.CertificateAuthorityCertificateAuthorityConfigurationArgs(
        key_algorithm="RSA_4096",
        signing_algorithm="SHA512WITHRSA",
        subject=aws.acmpca.CertificateAuthorityCertificateAuthorityConfigurationSubjectArgs(
            common_name="example.com",
        ),
    ))
    example_permission = aws.acmpca.Permission("examplePermission",
        certificate_authority_arn=example_certificate_authority.arn,
        actions=[
            "IssueCertificate",
            "GetCertificate",
            "ListPermissions",
        ],
        principal="acm.amazonaws.com")
    
    import * as pulumi from "@pulumi/pulumi";
    import * as aws from "@pulumi/aws";
    
    const exampleCertificateAuthority = new aws.acmpca.CertificateAuthority("exampleCertificateAuthority", {certificateAuthorityConfiguration: {
        keyAlgorithm: "RSA_4096",
        signingAlgorithm: "SHA512WITHRSA",
        subject: {
            commonName: "example.com",
        },
    }});
    const examplePermission = new aws.acmpca.Permission("examplePermission", {
        certificateAuthorityArn: exampleCertificateAuthority.arn,
        actions: [
            "IssueCertificate",
            "GetCertificate",
            "ListPermissions",
        ],
        principal: "acm.amazonaws.com",
    });
    
    resources:
      examplePermission:
        type: aws:acmpca:Permission
        properties:
          certificateAuthorityArn: ${exampleCertificateAuthority.arn}
          actions:
            - IssueCertificate
            - GetCertificate
            - ListPermissions
          principal: acm.amazonaws.com
      exampleCertificateAuthority:
        type: aws:acmpca:CertificateAuthority
        properties:
          certificateAuthorityConfiguration:
            keyAlgorithm: RSA_4096
            signingAlgorithm: SHA512WITHRSA
            subject:
              commonName: example.com
    

    Create Permission Resource

    new Permission(name: string, args: PermissionArgs, opts?: CustomResourceOptions);
    @overload
    def Permission(resource_name: str,
                   opts: Optional[ResourceOptions] = None,
                   actions: Optional[Sequence[str]] = None,
                   certificate_authority_arn: Optional[str] = None,
                   principal: Optional[str] = None,
                   source_account: Optional[str] = None)
    @overload
    def Permission(resource_name: str,
                   args: PermissionArgs,
                   opts: Optional[ResourceOptions] = None)
    func NewPermission(ctx *Context, name string, args PermissionArgs, opts ...ResourceOption) (*Permission, error)
    public Permission(string name, PermissionArgs args, CustomResourceOptions? opts = null)
    public Permission(String name, PermissionArgs args)
    public Permission(String name, PermissionArgs args, CustomResourceOptions options)
    
    type: aws:acmpca:Permission
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    
    name string
    The unique name of the resource.
    args PermissionArgs
    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 PermissionArgs
    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 PermissionArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args PermissionArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args PermissionArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

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

    Actions List<string>

    Actions that the specified AWS service principal can use. These include IssueCertificate, GetCertificate, and ListPermissions. Note that in order for ACM to automatically rotate certificates issued by a PCA, it must be granted permission on all 3 actions, as per the example above.

    CertificateAuthorityArn string

    ARN of the CA that grants the permissions.

    Principal string

    AWS service or identity that receives the permission. At this time, the only valid principal is acm.amazonaws.com.

    SourceAccount string

    ID of the calling account

    Actions []string

    Actions that the specified AWS service principal can use. These include IssueCertificate, GetCertificate, and ListPermissions. Note that in order for ACM to automatically rotate certificates issued by a PCA, it must be granted permission on all 3 actions, as per the example above.

    CertificateAuthorityArn string

    ARN of the CA that grants the permissions.

    Principal string

    AWS service or identity that receives the permission. At this time, the only valid principal is acm.amazonaws.com.

    SourceAccount string

    ID of the calling account

    actions List<String>

    Actions that the specified AWS service principal can use. These include IssueCertificate, GetCertificate, and ListPermissions. Note that in order for ACM to automatically rotate certificates issued by a PCA, it must be granted permission on all 3 actions, as per the example above.

    certificateAuthorityArn String

    ARN of the CA that grants the permissions.

    principal String

    AWS service or identity that receives the permission. At this time, the only valid principal is acm.amazonaws.com.

    sourceAccount String

    ID of the calling account

    actions string[]

    Actions that the specified AWS service principal can use. These include IssueCertificate, GetCertificate, and ListPermissions. Note that in order for ACM to automatically rotate certificates issued by a PCA, it must be granted permission on all 3 actions, as per the example above.

    certificateAuthorityArn string

    ARN of the CA that grants the permissions.

    principal string

    AWS service or identity that receives the permission. At this time, the only valid principal is acm.amazonaws.com.

    sourceAccount string

    ID of the calling account

    actions Sequence[str]

    Actions that the specified AWS service principal can use. These include IssueCertificate, GetCertificate, and ListPermissions. Note that in order for ACM to automatically rotate certificates issued by a PCA, it must be granted permission on all 3 actions, as per the example above.

    certificate_authority_arn str

    ARN of the CA that grants the permissions.

    principal str

    AWS service or identity that receives the permission. At this time, the only valid principal is acm.amazonaws.com.

    source_account str

    ID of the calling account

    actions List<String>

    Actions that the specified AWS service principal can use. These include IssueCertificate, GetCertificate, and ListPermissions. Note that in order for ACM to automatically rotate certificates issued by a PCA, it must be granted permission on all 3 actions, as per the example above.

    certificateAuthorityArn String

    ARN of the CA that grants the permissions.

    principal String

    AWS service or identity that receives the permission. At this time, the only valid principal is acm.amazonaws.com.

    sourceAccount String

    ID of the calling account

    Outputs

    All input properties are implicitly available as output properties. Additionally, the Permission resource produces the following output properties:

    Id string

    The provider-assigned unique ID for this managed resource.

    Policy string

    IAM policy that is associated with the permission.

    Id string

    The provider-assigned unique ID for this managed resource.

    Policy string

    IAM policy that is associated with the permission.

    id String

    The provider-assigned unique ID for this managed resource.

    policy String

    IAM policy that is associated with the permission.

    id string

    The provider-assigned unique ID for this managed resource.

    policy string

    IAM policy that is associated with the permission.

    id str

    The provider-assigned unique ID for this managed resource.

    policy str

    IAM policy that is associated with the permission.

    id String

    The provider-assigned unique ID for this managed resource.

    policy String

    IAM policy that is associated with the permission.

    Look up Existing Permission Resource

    Get an existing Permission 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?: PermissionState, opts?: CustomResourceOptions): Permission
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            actions: Optional[Sequence[str]] = None,
            certificate_authority_arn: Optional[str] = None,
            policy: Optional[str] = None,
            principal: Optional[str] = None,
            source_account: Optional[str] = None) -> Permission
    func GetPermission(ctx *Context, name string, id IDInput, state *PermissionState, opts ...ResourceOption) (*Permission, error)
    public static Permission Get(string name, Input<string> id, PermissionState? state, CustomResourceOptions? opts = null)
    public static Permission get(String name, Output<String> id, PermissionState 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:
    Actions List<string>

    Actions that the specified AWS service principal can use. These include IssueCertificate, GetCertificate, and ListPermissions. Note that in order for ACM to automatically rotate certificates issued by a PCA, it must be granted permission on all 3 actions, as per the example above.

    CertificateAuthorityArn string

    ARN of the CA that grants the permissions.

    Policy string

    IAM policy that is associated with the permission.

    Principal string

    AWS service or identity that receives the permission. At this time, the only valid principal is acm.amazonaws.com.

    SourceAccount string

    ID of the calling account

    Actions []string

    Actions that the specified AWS service principal can use. These include IssueCertificate, GetCertificate, and ListPermissions. Note that in order for ACM to automatically rotate certificates issued by a PCA, it must be granted permission on all 3 actions, as per the example above.

    CertificateAuthorityArn string

    ARN of the CA that grants the permissions.

    Policy string

    IAM policy that is associated with the permission.

    Principal string

    AWS service or identity that receives the permission. At this time, the only valid principal is acm.amazonaws.com.

    SourceAccount string

    ID of the calling account

    actions List<String>

    Actions that the specified AWS service principal can use. These include IssueCertificate, GetCertificate, and ListPermissions. Note that in order for ACM to automatically rotate certificates issued by a PCA, it must be granted permission on all 3 actions, as per the example above.

    certificateAuthorityArn String

    ARN of the CA that grants the permissions.

    policy String

    IAM policy that is associated with the permission.

    principal String

    AWS service or identity that receives the permission. At this time, the only valid principal is acm.amazonaws.com.

    sourceAccount String

    ID of the calling account

    actions string[]

    Actions that the specified AWS service principal can use. These include IssueCertificate, GetCertificate, and ListPermissions. Note that in order for ACM to automatically rotate certificates issued by a PCA, it must be granted permission on all 3 actions, as per the example above.

    certificateAuthorityArn string

    ARN of the CA that grants the permissions.

    policy string

    IAM policy that is associated with the permission.

    principal string

    AWS service or identity that receives the permission. At this time, the only valid principal is acm.amazonaws.com.

    sourceAccount string

    ID of the calling account

    actions Sequence[str]

    Actions that the specified AWS service principal can use. These include IssueCertificate, GetCertificate, and ListPermissions. Note that in order for ACM to automatically rotate certificates issued by a PCA, it must be granted permission on all 3 actions, as per the example above.

    certificate_authority_arn str

    ARN of the CA that grants the permissions.

    policy str

    IAM policy that is associated with the permission.

    principal str

    AWS service or identity that receives the permission. At this time, the only valid principal is acm.amazonaws.com.

    source_account str

    ID of the calling account

    actions List<String>

    Actions that the specified AWS service principal can use. These include IssueCertificate, GetCertificate, and ListPermissions. Note that in order for ACM to automatically rotate certificates issued by a PCA, it must be granted permission on all 3 actions, as per the example above.

    certificateAuthorityArn String

    ARN of the CA that grants the permissions.

    policy String

    IAM policy that is associated with the permission.

    principal String

    AWS service or identity that receives the permission. At this time, the only valid principal is acm.amazonaws.com.

    sourceAccount String

    ID of the calling account

    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 v5.41.0 published on Monday, May 15, 2023 by Pulumi