Interface ICfnKeyPairProps
Properties for defining a CfnKeyPair
.
Namespace: Amazon.CDK.AWS.EC2
Assembly: Amazon.CDK.AWS.EC2.dll
Syntax (csharp)
public interface ICfnKeyPairProps
Syntax (vb)
Public Interface ICfnKeyPairProps
Remarks
Link: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ec2-keypair.html
ExampleMetadata: fixture=_generated
Examples
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.EC2;
var cfnKeyPairProps = new CfnKeyPairProps {
KeyName = "keyName",
// the properties below are optional
KeyType = "keyType",
PublicKeyMaterial = "publicKeyMaterial",
Tags = new [] { new CfnTag {
Key = "key",
Value = "value"
} }
};
Synopsis
Properties
KeyName | A unique name for the key pair. |
KeyType | The type of key pair. Note that ED25519 keys are not supported for Windows instances. |
PublicKeyMaterial | The public key material. |
Tags | The tags to apply to the key pair. |
Properties
KeyName
A unique name for the key pair.
string KeyName { get; }
Property Value
System.String
Remarks
Constraints: Up to 255 ASCII characters
KeyType
The type of key pair. Note that ED25519 keys are not supported for Windows instances.
virtual string KeyType { get; }
Property Value
System.String
Remarks
If the PublicKeyMaterial
property is specified, the KeyType
property is ignored, and the key type is inferred from the PublicKeyMaterial
value.
Default: rsa
PublicKeyMaterial
The public key material.
virtual string PublicKeyMaterial { get; }
Property Value
System.String
Remarks
The PublicKeyMaterial
property is used to import a key pair. If this property is not specified, then a new key pair will be created.