Skip to main content

Provides an [EC2 key pair](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-key-pairs.html) resource. A key pair is used to control login access to EC2 instances.

Project description

tf-aws-keypair

AWS CDK L1 construct and data structures for the AWS CloudFormation Registry type TF::AWS::KeyPair v1.0.0.

Description

Provides an EC2 key pair resource. A key pair is used to control login access to EC2 instances.

Currently this resource requires an existing user-supplied key pair. This key pair's public key will be registered with AWS to allow logging-in to EC2 instances.

When importing an existing key pair the public key material may be in any format supported by AWS. Supported formats (per the AWS documentation) are:

  • OpenSSH public key format (the format in ~/.ssh/authorized_keys)
  • Base64 encoded DER format
  • SSH public key file format as specified in RFC4716

References

Usage

In order to use this library, you will need to activate this AWS CloudFormation Registry type in your account. You can do this via the AWS Management Console or using the AWS CLI using the following command:

aws cloudformation activate-type \
  --type-name TF::AWS::KeyPair \
  --publisher-id e1238fdd31aee1839e14fb3fb2dac9db154dae29 \
  --type RESOURCE \
  --execution-role-arn ROLE-ARN

Alternatively:

aws cloudformation activate-type \
  --public-type-arn arn:aws:cloudformation:us-east-1::type/resource/e1238fdd31aee1839e14fb3fb2dac9db154dae29/TF-AWS-KeyPair \
  --execution-role-arn ROLE-ARN

You can find more information about activating this type in the AWS CloudFormation documentation.

Feedback

This library is auto-generated and published to all supported programming languages by the cdklabs/cdk-cloudformation project based on the API schema published for TF::AWS::KeyPair.

  • Issues related to this generated library should be reported here.
  • Issues related to TF::AWS::KeyPair should be reported to the publisher.

License

Distributed under the Apache-2.0 License.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

Built Distribution

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page