github.com/pulumi/pulumi-aws/sdk/v6@v6.32.0/go/aws/iam/serverCertificate.go (about)

     1  // Code generated by the Pulumi Terraform Bridge (tfgen) Tool DO NOT EDIT.
     2  // *** WARNING: Do not edit by hand unless you're certain you know what you are doing! ***
     3  
     4  package iam
     5  
     6  import (
     7  	"context"
     8  	"reflect"
     9  
    10  	"errors"
    11  	"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/internal"
    12  	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    13  )
    14  
    15  // Provides an IAM Server Certificate resource to upload Server Certificates.
    16  // Certs uploaded to IAM can easily work with other AWS services such as:
    17  //
    18  // - AWS Elastic Beanstalk
    19  // - Elastic Load Balancing
    20  // - CloudFront
    21  // - AWS OpsWorks
    22  //
    23  // For information about server certificates in IAM, see [Managing Server
    24  // Certificates][2] in AWS Documentation.
    25  //
    26  // ## Example Usage
    27  //
    28  // **Using certs on file:**
    29  //
    30  // <!--Start PulumiCodeChooser -->
    31  // ```go
    32  // package main
    33  //
    34  // import (
    35  //
    36  //	"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/iam"
    37  //	"github.com/pulumi/pulumi-std/sdk/go/std"
    38  //	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    39  //
    40  // )
    41  //
    42  //	func main() {
    43  //		pulumi.Run(func(ctx *pulumi.Context) error {
    44  //			invokeFile, err := std.File(ctx, &std.FileArgs{
    45  //				Input: "self-ca-cert.pem",
    46  //			}, nil)
    47  //			if err != nil {
    48  //				return err
    49  //			}
    50  //			invokeFile1, err := std.File(ctx, &std.FileArgs{
    51  //				Input: "test-key.pem",
    52  //			}, nil)
    53  //			if err != nil {
    54  //				return err
    55  //			}
    56  //			_, err = iam.NewServerCertificate(ctx, "test_cert", &iam.ServerCertificateArgs{
    57  //				Name:            pulumi.String("some_test_cert"),
    58  //				CertificateBody: invokeFile.Result,
    59  //				PrivateKey:      invokeFile1.Result,
    60  //			})
    61  //			if err != nil {
    62  //				return err
    63  //			}
    64  //			return nil
    65  //		})
    66  //	}
    67  //
    68  // ```
    69  // <!--End PulumiCodeChooser -->
    70  //
    71  // **Example with cert in-line:**
    72  //
    73  // <!--Start PulumiCodeChooser -->
    74  // ```go
    75  // package main
    76  //
    77  // import (
    78  //
    79  //	"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/iam"
    80  //	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    81  //
    82  // )
    83  //
    84  //	func main() {
    85  //		pulumi.Run(func(ctx *pulumi.Context) error {
    86  //			_, err := iam.NewServerCertificate(ctx, "test_cert_alt", &iam.ServerCertificateArgs{
    87  //				Name:            pulumi.String("alt_test_cert"),
    88  //				CertificateBody: pulumi.String("-----BEGIN CERTIFICATE-----\n[......] # cert contents\n-----END CERTIFICATE-----\n"),
    89  //				PrivateKey:      pulumi.String("-----BEGIN RSA PRIVATE KEY-----\n[......] # cert contents\n-----END RSA PRIVATE KEY-----\n"),
    90  //			})
    91  //			if err != nil {
    92  //				return err
    93  //			}
    94  //			return nil
    95  //		})
    96  //	}
    97  //
    98  // ```
    99  // <!--End PulumiCodeChooser -->
   100  //
   101  // **Use in combination with an AWS ELB resource:**
   102  //
   103  // Some properties of an IAM Server Certificates cannot be updated while they are
   104  // in use. In order for the provider to effectively manage a Certificate in this situation, it is
   105  // recommended you utilize the `namePrefix` attribute and enable the
   106  // `createBeforeDestroy`. This will allow this provider
   107  // to create a new, updated `iam.ServerCertificate` resource and replace it in
   108  // dependant resources before attempting to destroy the old version.
   109  //
   110  // ## Import
   111  //
   112  // Using `pulumi import`, import IAM Server Certificates using the `name`. For example:
   113  //
   114  // ```sh
   115  // $ pulumi import aws:iam/serverCertificate:ServerCertificate certificate example.com-certificate-until-2018
   116  // ```
   117  type ServerCertificate struct {
   118  	pulumi.CustomResourceState
   119  
   120  	// The Amazon Resource Name (ARN) specifying the server certificate.
   121  	Arn pulumi.StringOutput `pulumi:"arn"`
   122  	// The contents of the public key certificate in
   123  	// PEM-encoded format.
   124  	CertificateBody pulumi.StringOutput `pulumi:"certificateBody"`
   125  	// The contents of the certificate chain.
   126  	// This is typically a concatenation of the PEM-encoded public key certificates
   127  	// of the chain.
   128  	CertificateChain pulumi.StringPtrOutput `pulumi:"certificateChain"`
   129  	// Date and time in [RFC3339 format](https://tools.ietf.org/html/rfc3339#section-5.8) on which the certificate is set to expire.
   130  	Expiration pulumi.StringOutput `pulumi:"expiration"`
   131  	// The name of the Server Certificate. Do not include the
   132  	// path in this value. If omitted, the provider will assign a random, unique name.
   133  	Name pulumi.StringOutput `pulumi:"name"`
   134  	// Creates a unique name beginning with the specified
   135  	// prefix. Conflicts with `name`.
   136  	NamePrefix pulumi.StringOutput `pulumi:"namePrefix"`
   137  	// The IAM path for the server certificate.  If it is not
   138  	// included, it defaults to a slash (/). If this certificate is for use with
   139  	// AWS CloudFront, the path must be in format `/cloudfront/your_path_here`.
   140  	// See [IAM Identifiers](https://docs.aws.amazon.com/IAM/latest/UserGuide/Using_Identifiers.html) for more details on IAM Paths.
   141  	Path pulumi.StringPtrOutput `pulumi:"path"`
   142  	// The contents of the private key in PEM-encoded format.
   143  	PrivateKey pulumi.StringOutput `pulumi:"privateKey"`
   144  	// Map of resource tags for the server certificate. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
   145  	//
   146  	// > **NOTE:** AWS performs behind-the-scenes modifications to some certificate files if they do not adhere to a specific format. These modifications will result in this provider forever believing that it needs to update the resources since the local and AWS file contents will not match after theses modifications occur. In order to prevent this from happening you must ensure that all your PEM-encoded files use UNIX line-breaks and that `certificateBody` contains only one certificate. All other certificates should go in `certificateChain`. It is common for some Certificate Authorities to issue certificate files that have DOS line-breaks and that are actually multiple certificates concatenated together in order to form a full certificate chain.
   147  	Tags pulumi.StringMapOutput `pulumi:"tags"`
   148  	// A map of tags assigned to the resource, including those inherited from the provider `defaultTags` configuration block.
   149  	//
   150  	// Deprecated: Please use `tags` instead.
   151  	TagsAll pulumi.StringMapOutput `pulumi:"tagsAll"`
   152  	// Date and time in [RFC3339 format](https://tools.ietf.org/html/rfc3339#section-5.8) when the server certificate was uploaded.
   153  	UploadDate pulumi.StringOutput `pulumi:"uploadDate"`
   154  }
   155  
   156  // NewServerCertificate registers a new resource with the given unique name, arguments, and options.
   157  func NewServerCertificate(ctx *pulumi.Context,
   158  	name string, args *ServerCertificateArgs, opts ...pulumi.ResourceOption) (*ServerCertificate, error) {
   159  	if args == nil {
   160  		return nil, errors.New("missing one or more required arguments")
   161  	}
   162  
   163  	if args.CertificateBody == nil {
   164  		return nil, errors.New("invalid value for required argument 'CertificateBody'")
   165  	}
   166  	if args.PrivateKey == nil {
   167  		return nil, errors.New("invalid value for required argument 'PrivateKey'")
   168  	}
   169  	if args.PrivateKey != nil {
   170  		args.PrivateKey = pulumi.ToSecret(args.PrivateKey).(pulumi.StringInput)
   171  	}
   172  	secrets := pulumi.AdditionalSecretOutputs([]string{
   173  		"privateKey",
   174  	})
   175  	opts = append(opts, secrets)
   176  	opts = internal.PkgResourceDefaultOpts(opts)
   177  	var resource ServerCertificate
   178  	err := ctx.RegisterResource("aws:iam/serverCertificate:ServerCertificate", name, args, &resource, opts...)
   179  	if err != nil {
   180  		return nil, err
   181  	}
   182  	return &resource, nil
   183  }
   184  
   185  // GetServerCertificate gets an existing ServerCertificate resource's state with the given name, ID, and optional
   186  // state properties that are used to uniquely qualify the lookup (nil if not required).
   187  func GetServerCertificate(ctx *pulumi.Context,
   188  	name string, id pulumi.IDInput, state *ServerCertificateState, opts ...pulumi.ResourceOption) (*ServerCertificate, error) {
   189  	var resource ServerCertificate
   190  	err := ctx.ReadResource("aws:iam/serverCertificate:ServerCertificate", name, id, state, &resource, opts...)
   191  	if err != nil {
   192  		return nil, err
   193  	}
   194  	return &resource, nil
   195  }
   196  
   197  // Input properties used for looking up and filtering ServerCertificate resources.
   198  type serverCertificateState struct {
   199  	// The Amazon Resource Name (ARN) specifying the server certificate.
   200  	Arn *string `pulumi:"arn"`
   201  	// The contents of the public key certificate in
   202  	// PEM-encoded format.
   203  	CertificateBody *string `pulumi:"certificateBody"`
   204  	// The contents of the certificate chain.
   205  	// This is typically a concatenation of the PEM-encoded public key certificates
   206  	// of the chain.
   207  	CertificateChain *string `pulumi:"certificateChain"`
   208  	// Date and time in [RFC3339 format](https://tools.ietf.org/html/rfc3339#section-5.8) on which the certificate is set to expire.
   209  	Expiration *string `pulumi:"expiration"`
   210  	// The name of the Server Certificate. Do not include the
   211  	// path in this value. If omitted, the provider will assign a random, unique name.
   212  	Name *string `pulumi:"name"`
   213  	// Creates a unique name beginning with the specified
   214  	// prefix. Conflicts with `name`.
   215  	NamePrefix *string `pulumi:"namePrefix"`
   216  	// The IAM path for the server certificate.  If it is not
   217  	// included, it defaults to a slash (/). If this certificate is for use with
   218  	// AWS CloudFront, the path must be in format `/cloudfront/your_path_here`.
   219  	// See [IAM Identifiers](https://docs.aws.amazon.com/IAM/latest/UserGuide/Using_Identifiers.html) for more details on IAM Paths.
   220  	Path *string `pulumi:"path"`
   221  	// The contents of the private key in PEM-encoded format.
   222  	PrivateKey *string `pulumi:"privateKey"`
   223  	// Map of resource tags for the server certificate. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
   224  	//
   225  	// > **NOTE:** AWS performs behind-the-scenes modifications to some certificate files if they do not adhere to a specific format. These modifications will result in this provider forever believing that it needs to update the resources since the local and AWS file contents will not match after theses modifications occur. In order to prevent this from happening you must ensure that all your PEM-encoded files use UNIX line-breaks and that `certificateBody` contains only one certificate. All other certificates should go in `certificateChain`. It is common for some Certificate Authorities to issue certificate files that have DOS line-breaks and that are actually multiple certificates concatenated together in order to form a full certificate chain.
   226  	Tags map[string]string `pulumi:"tags"`
   227  	// A map of tags assigned to the resource, including those inherited from the provider `defaultTags` configuration block.
   228  	//
   229  	// Deprecated: Please use `tags` instead.
   230  	TagsAll map[string]string `pulumi:"tagsAll"`
   231  	// Date and time in [RFC3339 format](https://tools.ietf.org/html/rfc3339#section-5.8) when the server certificate was uploaded.
   232  	UploadDate *string `pulumi:"uploadDate"`
   233  }
   234  
   235  type ServerCertificateState struct {
   236  	// The Amazon Resource Name (ARN) specifying the server certificate.
   237  	Arn pulumi.StringPtrInput
   238  	// The contents of the public key certificate in
   239  	// PEM-encoded format.
   240  	CertificateBody pulumi.StringPtrInput
   241  	// The contents of the certificate chain.
   242  	// This is typically a concatenation of the PEM-encoded public key certificates
   243  	// of the chain.
   244  	CertificateChain pulumi.StringPtrInput
   245  	// Date and time in [RFC3339 format](https://tools.ietf.org/html/rfc3339#section-5.8) on which the certificate is set to expire.
   246  	Expiration pulumi.StringPtrInput
   247  	// The name of the Server Certificate. Do not include the
   248  	// path in this value. If omitted, the provider will assign a random, unique name.
   249  	Name pulumi.StringPtrInput
   250  	// Creates a unique name beginning with the specified
   251  	// prefix. Conflicts with `name`.
   252  	NamePrefix pulumi.StringPtrInput
   253  	// The IAM path for the server certificate.  If it is not
   254  	// included, it defaults to a slash (/). If this certificate is for use with
   255  	// AWS CloudFront, the path must be in format `/cloudfront/your_path_here`.
   256  	// See [IAM Identifiers](https://docs.aws.amazon.com/IAM/latest/UserGuide/Using_Identifiers.html) for more details on IAM Paths.
   257  	Path pulumi.StringPtrInput
   258  	// The contents of the private key in PEM-encoded format.
   259  	PrivateKey pulumi.StringPtrInput
   260  	// Map of resource tags for the server certificate. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
   261  	//
   262  	// > **NOTE:** AWS performs behind-the-scenes modifications to some certificate files if they do not adhere to a specific format. These modifications will result in this provider forever believing that it needs to update the resources since the local and AWS file contents will not match after theses modifications occur. In order to prevent this from happening you must ensure that all your PEM-encoded files use UNIX line-breaks and that `certificateBody` contains only one certificate. All other certificates should go in `certificateChain`. It is common for some Certificate Authorities to issue certificate files that have DOS line-breaks and that are actually multiple certificates concatenated together in order to form a full certificate chain.
   263  	Tags pulumi.StringMapInput
   264  	// A map of tags assigned to the resource, including those inherited from the provider `defaultTags` configuration block.
   265  	//
   266  	// Deprecated: Please use `tags` instead.
   267  	TagsAll pulumi.StringMapInput
   268  	// Date and time in [RFC3339 format](https://tools.ietf.org/html/rfc3339#section-5.8) when the server certificate was uploaded.
   269  	UploadDate pulumi.StringPtrInput
   270  }
   271  
   272  func (ServerCertificateState) ElementType() reflect.Type {
   273  	return reflect.TypeOf((*serverCertificateState)(nil)).Elem()
   274  }
   275  
   276  type serverCertificateArgs struct {
   277  	// The contents of the public key certificate in
   278  	// PEM-encoded format.
   279  	CertificateBody string `pulumi:"certificateBody"`
   280  	// The contents of the certificate chain.
   281  	// This is typically a concatenation of the PEM-encoded public key certificates
   282  	// of the chain.
   283  	CertificateChain *string `pulumi:"certificateChain"`
   284  	// The name of the Server Certificate. Do not include the
   285  	// path in this value. If omitted, the provider will assign a random, unique name.
   286  	Name *string `pulumi:"name"`
   287  	// Creates a unique name beginning with the specified
   288  	// prefix. Conflicts with `name`.
   289  	NamePrefix *string `pulumi:"namePrefix"`
   290  	// The IAM path for the server certificate.  If it is not
   291  	// included, it defaults to a slash (/). If this certificate is for use with
   292  	// AWS CloudFront, the path must be in format `/cloudfront/your_path_here`.
   293  	// See [IAM Identifiers](https://docs.aws.amazon.com/IAM/latest/UserGuide/Using_Identifiers.html) for more details on IAM Paths.
   294  	Path *string `pulumi:"path"`
   295  	// The contents of the private key in PEM-encoded format.
   296  	PrivateKey string `pulumi:"privateKey"`
   297  	// Map of resource tags for the server certificate. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
   298  	//
   299  	// > **NOTE:** AWS performs behind-the-scenes modifications to some certificate files if they do not adhere to a specific format. These modifications will result in this provider forever believing that it needs to update the resources since the local and AWS file contents will not match after theses modifications occur. In order to prevent this from happening you must ensure that all your PEM-encoded files use UNIX line-breaks and that `certificateBody` contains only one certificate. All other certificates should go in `certificateChain`. It is common for some Certificate Authorities to issue certificate files that have DOS line-breaks and that are actually multiple certificates concatenated together in order to form a full certificate chain.
   300  	Tags map[string]string `pulumi:"tags"`
   301  }
   302  
   303  // The set of arguments for constructing a ServerCertificate resource.
   304  type ServerCertificateArgs struct {
   305  	// The contents of the public key certificate in
   306  	// PEM-encoded format.
   307  	CertificateBody pulumi.StringInput
   308  	// The contents of the certificate chain.
   309  	// This is typically a concatenation of the PEM-encoded public key certificates
   310  	// of the chain.
   311  	CertificateChain pulumi.StringPtrInput
   312  	// The name of the Server Certificate. Do not include the
   313  	// path in this value. If omitted, the provider will assign a random, unique name.
   314  	Name pulumi.StringPtrInput
   315  	// Creates a unique name beginning with the specified
   316  	// prefix. Conflicts with `name`.
   317  	NamePrefix pulumi.StringPtrInput
   318  	// The IAM path for the server certificate.  If it is not
   319  	// included, it defaults to a slash (/). If this certificate is for use with
   320  	// AWS CloudFront, the path must be in format `/cloudfront/your_path_here`.
   321  	// See [IAM Identifiers](https://docs.aws.amazon.com/IAM/latest/UserGuide/Using_Identifiers.html) for more details on IAM Paths.
   322  	Path pulumi.StringPtrInput
   323  	// The contents of the private key in PEM-encoded format.
   324  	PrivateKey pulumi.StringInput
   325  	// Map of resource tags for the server certificate. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
   326  	//
   327  	// > **NOTE:** AWS performs behind-the-scenes modifications to some certificate files if they do not adhere to a specific format. These modifications will result in this provider forever believing that it needs to update the resources since the local and AWS file contents will not match after theses modifications occur. In order to prevent this from happening you must ensure that all your PEM-encoded files use UNIX line-breaks and that `certificateBody` contains only one certificate. All other certificates should go in `certificateChain`. It is common for some Certificate Authorities to issue certificate files that have DOS line-breaks and that are actually multiple certificates concatenated together in order to form a full certificate chain.
   328  	Tags pulumi.StringMapInput
   329  }
   330  
   331  func (ServerCertificateArgs) ElementType() reflect.Type {
   332  	return reflect.TypeOf((*serverCertificateArgs)(nil)).Elem()
   333  }
   334  
   335  type ServerCertificateInput interface {
   336  	pulumi.Input
   337  
   338  	ToServerCertificateOutput() ServerCertificateOutput
   339  	ToServerCertificateOutputWithContext(ctx context.Context) ServerCertificateOutput
   340  }
   341  
   342  func (*ServerCertificate) ElementType() reflect.Type {
   343  	return reflect.TypeOf((**ServerCertificate)(nil)).Elem()
   344  }
   345  
   346  func (i *ServerCertificate) ToServerCertificateOutput() ServerCertificateOutput {
   347  	return i.ToServerCertificateOutputWithContext(context.Background())
   348  }
   349  
   350  func (i *ServerCertificate) ToServerCertificateOutputWithContext(ctx context.Context) ServerCertificateOutput {
   351  	return pulumi.ToOutputWithContext(ctx, i).(ServerCertificateOutput)
   352  }
   353  
   354  // ServerCertificateArrayInput is an input type that accepts ServerCertificateArray and ServerCertificateArrayOutput values.
   355  // You can construct a concrete instance of `ServerCertificateArrayInput` via:
   356  //
   357  //	ServerCertificateArray{ ServerCertificateArgs{...} }
   358  type ServerCertificateArrayInput interface {
   359  	pulumi.Input
   360  
   361  	ToServerCertificateArrayOutput() ServerCertificateArrayOutput
   362  	ToServerCertificateArrayOutputWithContext(context.Context) ServerCertificateArrayOutput
   363  }
   364  
   365  type ServerCertificateArray []ServerCertificateInput
   366  
   367  func (ServerCertificateArray) ElementType() reflect.Type {
   368  	return reflect.TypeOf((*[]*ServerCertificate)(nil)).Elem()
   369  }
   370  
   371  func (i ServerCertificateArray) ToServerCertificateArrayOutput() ServerCertificateArrayOutput {
   372  	return i.ToServerCertificateArrayOutputWithContext(context.Background())
   373  }
   374  
   375  func (i ServerCertificateArray) ToServerCertificateArrayOutputWithContext(ctx context.Context) ServerCertificateArrayOutput {
   376  	return pulumi.ToOutputWithContext(ctx, i).(ServerCertificateArrayOutput)
   377  }
   378  
   379  // ServerCertificateMapInput is an input type that accepts ServerCertificateMap and ServerCertificateMapOutput values.
   380  // You can construct a concrete instance of `ServerCertificateMapInput` via:
   381  //
   382  //	ServerCertificateMap{ "key": ServerCertificateArgs{...} }
   383  type ServerCertificateMapInput interface {
   384  	pulumi.Input
   385  
   386  	ToServerCertificateMapOutput() ServerCertificateMapOutput
   387  	ToServerCertificateMapOutputWithContext(context.Context) ServerCertificateMapOutput
   388  }
   389  
   390  type ServerCertificateMap map[string]ServerCertificateInput
   391  
   392  func (ServerCertificateMap) ElementType() reflect.Type {
   393  	return reflect.TypeOf((*map[string]*ServerCertificate)(nil)).Elem()
   394  }
   395  
   396  func (i ServerCertificateMap) ToServerCertificateMapOutput() ServerCertificateMapOutput {
   397  	return i.ToServerCertificateMapOutputWithContext(context.Background())
   398  }
   399  
   400  func (i ServerCertificateMap) ToServerCertificateMapOutputWithContext(ctx context.Context) ServerCertificateMapOutput {
   401  	return pulumi.ToOutputWithContext(ctx, i).(ServerCertificateMapOutput)
   402  }
   403  
   404  type ServerCertificateOutput struct{ *pulumi.OutputState }
   405  
   406  func (ServerCertificateOutput) ElementType() reflect.Type {
   407  	return reflect.TypeOf((**ServerCertificate)(nil)).Elem()
   408  }
   409  
   410  func (o ServerCertificateOutput) ToServerCertificateOutput() ServerCertificateOutput {
   411  	return o
   412  }
   413  
   414  func (o ServerCertificateOutput) ToServerCertificateOutputWithContext(ctx context.Context) ServerCertificateOutput {
   415  	return o
   416  }
   417  
   418  // The Amazon Resource Name (ARN) specifying the server certificate.
   419  func (o ServerCertificateOutput) Arn() pulumi.StringOutput {
   420  	return o.ApplyT(func(v *ServerCertificate) pulumi.StringOutput { return v.Arn }).(pulumi.StringOutput)
   421  }
   422  
   423  // The contents of the public key certificate in
   424  // PEM-encoded format.
   425  func (o ServerCertificateOutput) CertificateBody() pulumi.StringOutput {
   426  	return o.ApplyT(func(v *ServerCertificate) pulumi.StringOutput { return v.CertificateBody }).(pulumi.StringOutput)
   427  }
   428  
   429  // The contents of the certificate chain.
   430  // This is typically a concatenation of the PEM-encoded public key certificates
   431  // of the chain.
   432  func (o ServerCertificateOutput) CertificateChain() pulumi.StringPtrOutput {
   433  	return o.ApplyT(func(v *ServerCertificate) pulumi.StringPtrOutput { return v.CertificateChain }).(pulumi.StringPtrOutput)
   434  }
   435  
   436  // Date and time in [RFC3339 format](https://tools.ietf.org/html/rfc3339#section-5.8) on which the certificate is set to expire.
   437  func (o ServerCertificateOutput) Expiration() pulumi.StringOutput {
   438  	return o.ApplyT(func(v *ServerCertificate) pulumi.StringOutput { return v.Expiration }).(pulumi.StringOutput)
   439  }
   440  
   441  // The name of the Server Certificate. Do not include the
   442  // path in this value. If omitted, the provider will assign a random, unique name.
   443  func (o ServerCertificateOutput) Name() pulumi.StringOutput {
   444  	return o.ApplyT(func(v *ServerCertificate) pulumi.StringOutput { return v.Name }).(pulumi.StringOutput)
   445  }
   446  
   447  // Creates a unique name beginning with the specified
   448  // prefix. Conflicts with `name`.
   449  func (o ServerCertificateOutput) NamePrefix() pulumi.StringOutput {
   450  	return o.ApplyT(func(v *ServerCertificate) pulumi.StringOutput { return v.NamePrefix }).(pulumi.StringOutput)
   451  }
   452  
   453  // The IAM path for the server certificate.  If it is not
   454  // included, it defaults to a slash (/). If this certificate is for use with
   455  // AWS CloudFront, the path must be in format `/cloudfront/your_path_here`.
   456  // See [IAM Identifiers](https://docs.aws.amazon.com/IAM/latest/UserGuide/Using_Identifiers.html) for more details on IAM Paths.
   457  func (o ServerCertificateOutput) Path() pulumi.StringPtrOutput {
   458  	return o.ApplyT(func(v *ServerCertificate) pulumi.StringPtrOutput { return v.Path }).(pulumi.StringPtrOutput)
   459  }
   460  
   461  // The contents of the private key in PEM-encoded format.
   462  func (o ServerCertificateOutput) PrivateKey() pulumi.StringOutput {
   463  	return o.ApplyT(func(v *ServerCertificate) pulumi.StringOutput { return v.PrivateKey }).(pulumi.StringOutput)
   464  }
   465  
   466  // Map of resource tags for the server certificate. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
   467  //
   468  // > **NOTE:** AWS performs behind-the-scenes modifications to some certificate files if they do not adhere to a specific format. These modifications will result in this provider forever believing that it needs to update the resources since the local and AWS file contents will not match after theses modifications occur. In order to prevent this from happening you must ensure that all your PEM-encoded files use UNIX line-breaks and that `certificateBody` contains only one certificate. All other certificates should go in `certificateChain`. It is common for some Certificate Authorities to issue certificate files that have DOS line-breaks and that are actually multiple certificates concatenated together in order to form a full certificate chain.
   469  func (o ServerCertificateOutput) Tags() pulumi.StringMapOutput {
   470  	return o.ApplyT(func(v *ServerCertificate) pulumi.StringMapOutput { return v.Tags }).(pulumi.StringMapOutput)
   471  }
   472  
   473  // A map of tags assigned to the resource, including those inherited from the provider `defaultTags` configuration block.
   474  //
   475  // Deprecated: Please use `tags` instead.
   476  func (o ServerCertificateOutput) TagsAll() pulumi.StringMapOutput {
   477  	return o.ApplyT(func(v *ServerCertificate) pulumi.StringMapOutput { return v.TagsAll }).(pulumi.StringMapOutput)
   478  }
   479  
   480  // Date and time in [RFC3339 format](https://tools.ietf.org/html/rfc3339#section-5.8) when the server certificate was uploaded.
   481  func (o ServerCertificateOutput) UploadDate() pulumi.StringOutput {
   482  	return o.ApplyT(func(v *ServerCertificate) pulumi.StringOutput { return v.UploadDate }).(pulumi.StringOutput)
   483  }
   484  
   485  type ServerCertificateArrayOutput struct{ *pulumi.OutputState }
   486  
   487  func (ServerCertificateArrayOutput) ElementType() reflect.Type {
   488  	return reflect.TypeOf((*[]*ServerCertificate)(nil)).Elem()
   489  }
   490  
   491  func (o ServerCertificateArrayOutput) ToServerCertificateArrayOutput() ServerCertificateArrayOutput {
   492  	return o
   493  }
   494  
   495  func (o ServerCertificateArrayOutput) ToServerCertificateArrayOutputWithContext(ctx context.Context) ServerCertificateArrayOutput {
   496  	return o
   497  }
   498  
   499  func (o ServerCertificateArrayOutput) Index(i pulumi.IntInput) ServerCertificateOutput {
   500  	return pulumi.All(o, i).ApplyT(func(vs []interface{}) *ServerCertificate {
   501  		return vs[0].([]*ServerCertificate)[vs[1].(int)]
   502  	}).(ServerCertificateOutput)
   503  }
   504  
   505  type ServerCertificateMapOutput struct{ *pulumi.OutputState }
   506  
   507  func (ServerCertificateMapOutput) ElementType() reflect.Type {
   508  	return reflect.TypeOf((*map[string]*ServerCertificate)(nil)).Elem()
   509  }
   510  
   511  func (o ServerCertificateMapOutput) ToServerCertificateMapOutput() ServerCertificateMapOutput {
   512  	return o
   513  }
   514  
   515  func (o ServerCertificateMapOutput) ToServerCertificateMapOutputWithContext(ctx context.Context) ServerCertificateMapOutput {
   516  	return o
   517  }
   518  
   519  func (o ServerCertificateMapOutput) MapIndex(k pulumi.StringInput) ServerCertificateOutput {
   520  	return pulumi.All(o, k).ApplyT(func(vs []interface{}) *ServerCertificate {
   521  		return vs[0].(map[string]*ServerCertificate)[vs[1].(string)]
   522  	}).(ServerCertificateOutput)
   523  }
   524  
   525  func init() {
   526  	pulumi.RegisterInputType(reflect.TypeOf((*ServerCertificateInput)(nil)).Elem(), &ServerCertificate{})
   527  	pulumi.RegisterInputType(reflect.TypeOf((*ServerCertificateArrayInput)(nil)).Elem(), ServerCertificateArray{})
   528  	pulumi.RegisterInputType(reflect.TypeOf((*ServerCertificateMapInput)(nil)).Elem(), ServerCertificateMap{})
   529  	pulumi.RegisterOutputType(ServerCertificateOutput{})
   530  	pulumi.RegisterOutputType(ServerCertificateArrayOutput{})
   531  	pulumi.RegisterOutputType(ServerCertificateMapOutput{})
   532  }