Copyright | (c) 2013-2021 Brendan Hay |
---|---|
License | Mozilla Public License, v. 2.0. |
Maintainer | Brendan Hay <brendan.g.hay+amazonka@gmail.com> |
Stability | auto-generated |
Portability | non-portable (GHC extensions) |
Safe Haskell | None |
Creates one or more new instances from a manual or automatic snapshot of an instance.
The create instances from snapshot
operation supports tag-based access
control via request tags and resource tags applied to the resource
identified by instance snapshot name
. For more information, see the
Amazon Lightsail Developer Guide.
Synopsis
- data CreateInstancesFromSnapshot = CreateInstancesFromSnapshot' {
- useLatestRestorableAutoSnapshot :: Maybe Bool
- instanceSnapshotName :: Maybe Text
- addOns :: Maybe [AddOnRequest]
- userData :: Maybe Text
- restoreDate :: Maybe Text
- ipAddressType :: Maybe IpAddressType
- keyPairName :: Maybe Text
- sourceInstanceName :: Maybe Text
- attachedDiskMapping :: Maybe (HashMap Text [DiskMap])
- tags :: Maybe [Tag]
- instanceNames :: [Text]
- availabilityZone :: Text
- bundleId :: Text
- newCreateInstancesFromSnapshot :: Text -> Text -> CreateInstancesFromSnapshot
- createInstancesFromSnapshot_useLatestRestorableAutoSnapshot :: Lens' CreateInstancesFromSnapshot (Maybe Bool)
- createInstancesFromSnapshot_instanceSnapshotName :: Lens' CreateInstancesFromSnapshot (Maybe Text)
- createInstancesFromSnapshot_addOns :: Lens' CreateInstancesFromSnapshot (Maybe [AddOnRequest])
- createInstancesFromSnapshot_userData :: Lens' CreateInstancesFromSnapshot (Maybe Text)
- createInstancesFromSnapshot_restoreDate :: Lens' CreateInstancesFromSnapshot (Maybe Text)
- createInstancesFromSnapshot_ipAddressType :: Lens' CreateInstancesFromSnapshot (Maybe IpAddressType)
- createInstancesFromSnapshot_keyPairName :: Lens' CreateInstancesFromSnapshot (Maybe Text)
- createInstancesFromSnapshot_sourceInstanceName :: Lens' CreateInstancesFromSnapshot (Maybe Text)
- createInstancesFromSnapshot_attachedDiskMapping :: Lens' CreateInstancesFromSnapshot (Maybe (HashMap Text [DiskMap]))
- createInstancesFromSnapshot_tags :: Lens' CreateInstancesFromSnapshot (Maybe [Tag])
- createInstancesFromSnapshot_instanceNames :: Lens' CreateInstancesFromSnapshot [Text]
- createInstancesFromSnapshot_availabilityZone :: Lens' CreateInstancesFromSnapshot Text
- createInstancesFromSnapshot_bundleId :: Lens' CreateInstancesFromSnapshot Text
- data CreateInstancesFromSnapshotResponse = CreateInstancesFromSnapshotResponse' {
- operations :: Maybe [Operation]
- httpStatus :: Int
- newCreateInstancesFromSnapshotResponse :: Int -> CreateInstancesFromSnapshotResponse
- createInstancesFromSnapshotResponse_operations :: Lens' CreateInstancesFromSnapshotResponse (Maybe [Operation])
- createInstancesFromSnapshotResponse_httpStatus :: Lens' CreateInstancesFromSnapshotResponse Int
Creating a Request
data CreateInstancesFromSnapshot Source #
See: newCreateInstancesFromSnapshot
smart constructor.
CreateInstancesFromSnapshot' | |
|
Instances
newCreateInstancesFromSnapshot Source #
:: Text | |
-> Text | |
-> CreateInstancesFromSnapshot |
Create a value of CreateInstancesFromSnapshot
with all optional fields omitted.
Use generic-lens or optics to modify other optional fields.
The following record fields are available, with the corresponding lenses provided for backwards compatibility:
$sel:useLatestRestorableAutoSnapshot:CreateInstancesFromSnapshot'
, createInstancesFromSnapshot_useLatestRestorableAutoSnapshot
- A Boolean value to indicate whether to use the latest available
automatic snapshot.
Constraints:
- This parameter cannot be defined together with the
restore date
parameter. Theuse latest restorable auto snapshot
andrestore date
parameters are mutually exclusive. - Define this parameter only when creating a new instance from an automatic snapshot. For more information, see the Amazon Lightsail Developer Guide.
$sel:instanceSnapshotName:CreateInstancesFromSnapshot'
, createInstancesFromSnapshot_instanceSnapshotName
- The name of the instance snapshot on which you are basing your new
instances. Use the get instance snapshots operation to return
information about your existing snapshots.
Constraint:
- This parameter cannot be defined together with the
source instance name
parameter. Theinstance snapshot name
andsource instance name
parameters are mutually exclusive.
$sel:addOns:CreateInstancesFromSnapshot'
, createInstancesFromSnapshot_addOns
- An array of objects representing the add-ons to enable for the new
instance.
$sel:userData:CreateInstancesFromSnapshot'
, createInstancesFromSnapshot_userData
- You can create a launch script that configures a server with additional
user data. For example, apt-get -y update
.
Depending on the machine image you choose, the command to get software
on your instance varies. Amazon Linux and CentOS use yum
, Debian and
Ubuntu use apt-get
, and FreeBSD uses pkg
. For a complete list, see
the
Amazon Lightsail Developer Guide.
$sel:restoreDate:CreateInstancesFromSnapshot'
, createInstancesFromSnapshot_restoreDate
- The date of the automatic snapshot to use for the new instance. Use the
get auto snapshots
operation to identify the dates of the available
automatic snapshots.
Constraints:
- Must be specified in
YYYY-MM-DD
format. - This parameter cannot be defined together with the
use latest restorable auto snapshot
parameter. Therestore date
anduse latest restorable auto snapshot
parameters are mutually exclusive. - Define this parameter only when creating a new instance from an automatic snapshot. For more information, see the Amazon Lightsail Developer Guide.
$sel:ipAddressType:CreateInstancesFromSnapshot'
, createInstancesFromSnapshot_ipAddressType
- The IP address type for the instance.
The possible values are ipv4
for IPv4 only, and dualstack
for IPv4
and IPv6.
The default value is dualstack
.
$sel:keyPairName:CreateInstancesFromSnapshot'
, createInstancesFromSnapshot_keyPairName
- The name for your key pair.
$sel:sourceInstanceName:CreateInstancesFromSnapshot'
, createInstancesFromSnapshot_sourceInstanceName
- The name of the source instance from which the source automatic snapshot
was created.
Constraints:
- This parameter cannot be defined together with the
instance snapshot name
parameter. Thesource instance name
andinstance snapshot name
parameters are mutually exclusive. - Define this parameter only when creating a new instance from an automatic snapshot. For more information, see the Amazon Lightsail Developer Guide.
$sel:attachedDiskMapping:CreateInstancesFromSnapshot'
, createInstancesFromSnapshot_attachedDiskMapping
- An object containing information about one or more disk mappings.
$sel:tags:CreateInstancesFromSnapshot'
, createInstancesFromSnapshot_tags
- The tag keys and optional values to add to the resource during create.
Use the TagResource
action to tag a resource after it's created.
$sel:instanceNames:CreateInstancesFromSnapshot'
, createInstancesFromSnapshot_instanceNames
- The names for your new instances.
$sel:availabilityZone:CreateInstancesFromSnapshot'
, createInstancesFromSnapshot_availabilityZone
- The Availability Zone where you want to create your instances. Use the
following formatting: us-east-2a
(case sensitive). You can get a list
of Availability Zones by using the
get regions
operation. Be sure to add the include Availability Zones
parameter to
your request.
$sel:bundleId:CreateInstancesFromSnapshot'
, createInstancesFromSnapshot_bundleId
- The bundle of specification information for your virtual private server
(or instance), including the pricing plan (e.g., micro_1_0
).
Request Lenses
createInstancesFromSnapshot_useLatestRestorableAutoSnapshot :: Lens' CreateInstancesFromSnapshot (Maybe Bool) Source #
A Boolean value to indicate whether to use the latest available automatic snapshot.
Constraints:
- This parameter cannot be defined together with the
restore date
parameter. Theuse latest restorable auto snapshot
andrestore date
parameters are mutually exclusive. - Define this parameter only when creating a new instance from an automatic snapshot. For more information, see the Amazon Lightsail Developer Guide.
createInstancesFromSnapshot_instanceSnapshotName :: Lens' CreateInstancesFromSnapshot (Maybe Text) Source #
The name of the instance snapshot on which you are basing your new instances. Use the get instance snapshots operation to return information about your existing snapshots.
Constraint:
- This parameter cannot be defined together with the
source instance name
parameter. Theinstance snapshot name
andsource instance name
parameters are mutually exclusive.
createInstancesFromSnapshot_addOns :: Lens' CreateInstancesFromSnapshot (Maybe [AddOnRequest]) Source #
An array of objects representing the add-ons to enable for the new instance.
createInstancesFromSnapshot_userData :: Lens' CreateInstancesFromSnapshot (Maybe Text) Source #
You can create a launch script that configures a server with additional
user data. For example, apt-get -y update
.
Depending on the machine image you choose, the command to get software
on your instance varies. Amazon Linux and CentOS use yum
, Debian and
Ubuntu use apt-get
, and FreeBSD uses pkg
. For a complete list, see
the
Amazon Lightsail Developer Guide.
createInstancesFromSnapshot_restoreDate :: Lens' CreateInstancesFromSnapshot (Maybe Text) Source #
The date of the automatic snapshot to use for the new instance. Use the
get auto snapshots
operation to identify the dates of the available
automatic snapshots.
Constraints:
- Must be specified in
YYYY-MM-DD
format. - This parameter cannot be defined together with the
use latest restorable auto snapshot
parameter. Therestore date
anduse latest restorable auto snapshot
parameters are mutually exclusive. - Define this parameter only when creating a new instance from an automatic snapshot. For more information, see the Amazon Lightsail Developer Guide.
createInstancesFromSnapshot_ipAddressType :: Lens' CreateInstancesFromSnapshot (Maybe IpAddressType) Source #
The IP address type for the instance.
The possible values are ipv4
for IPv4 only, and dualstack
for IPv4
and IPv6.
The default value is dualstack
.
createInstancesFromSnapshot_keyPairName :: Lens' CreateInstancesFromSnapshot (Maybe Text) Source #
The name for your key pair.
createInstancesFromSnapshot_sourceInstanceName :: Lens' CreateInstancesFromSnapshot (Maybe Text) Source #
The name of the source instance from which the source automatic snapshot was created.
Constraints:
- This parameter cannot be defined together with the
instance snapshot name
parameter. Thesource instance name
andinstance snapshot name
parameters are mutually exclusive. - Define this parameter only when creating a new instance from an automatic snapshot. For more information, see the Amazon Lightsail Developer Guide.
createInstancesFromSnapshot_attachedDiskMapping :: Lens' CreateInstancesFromSnapshot (Maybe (HashMap Text [DiskMap])) Source #
An object containing information about one or more disk mappings.
createInstancesFromSnapshot_tags :: Lens' CreateInstancesFromSnapshot (Maybe [Tag]) Source #
The tag keys and optional values to add to the resource during create.
Use the TagResource
action to tag a resource after it's created.
createInstancesFromSnapshot_instanceNames :: Lens' CreateInstancesFromSnapshot [Text] Source #
The names for your new instances.
createInstancesFromSnapshot_availabilityZone :: Lens' CreateInstancesFromSnapshot Text Source #
The Availability Zone where you want to create your instances. Use the
following formatting: us-east-2a
(case sensitive). You can get a list
of Availability Zones by using the
get regions
operation. Be sure to add the include Availability Zones
parameter to
your request.
createInstancesFromSnapshot_bundleId :: Lens' CreateInstancesFromSnapshot Text Source #
The bundle of specification information for your virtual private server
(or instance), including the pricing plan (e.g., micro_1_0
).
Destructuring the Response
data CreateInstancesFromSnapshotResponse Source #
See: newCreateInstancesFromSnapshotResponse
smart constructor.
CreateInstancesFromSnapshotResponse' | |
|
Instances
Eq CreateInstancesFromSnapshotResponse Source # | |
Read CreateInstancesFromSnapshotResponse Source # | |
Show CreateInstancesFromSnapshotResponse Source # | |
Generic CreateInstancesFromSnapshotResponse Source # | |
NFData CreateInstancesFromSnapshotResponse Source # | |
Defined in Amazonka.Lightsail.CreateInstancesFromSnapshot rnf :: CreateInstancesFromSnapshotResponse -> () # | |
type Rep CreateInstancesFromSnapshotResponse Source # | |
Defined in Amazonka.Lightsail.CreateInstancesFromSnapshot type Rep CreateInstancesFromSnapshotResponse = D1 ('MetaData "CreateInstancesFromSnapshotResponse" "Amazonka.Lightsail.CreateInstancesFromSnapshot" "libZSservicesZSamazonka-lightsailZSamazonka-lightsail" 'False) (C1 ('MetaCons "CreateInstancesFromSnapshotResponse'" 'PrefixI 'True) (S1 ('MetaSel ('Just "operations") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe [Operation])) :*: S1 ('MetaSel ('Just "httpStatus") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Int))) |
newCreateInstancesFromSnapshotResponse Source #
Create a value of CreateInstancesFromSnapshotResponse
with all optional fields omitted.
Use generic-lens or optics to modify other optional fields.
The following record fields are available, with the corresponding lenses provided for backwards compatibility:
$sel:operations:CreateInstancesFromSnapshotResponse'
, createInstancesFromSnapshotResponse_operations
- An array of objects that describe the result of the action, such as the
status of the request, the timestamp of the request, and the resources
affected by the request.
$sel:httpStatus:CreateInstancesFromSnapshotResponse'
, createInstancesFromSnapshotResponse_httpStatus
- The response's http status code.
Response Lenses
createInstancesFromSnapshotResponse_operations :: Lens' CreateInstancesFromSnapshotResponse (Maybe [Operation]) Source #
An array of objects that describe the result of the action, such as the status of the request, the timestamp of the request, and the resources affected by the request.
createInstancesFromSnapshotResponse_httpStatus :: Lens' CreateInstancesFromSnapshotResponse Int Source #
The response's http status code.