Class: Aws::Lightsail::Types::CreateInstancesFromSnapshotRequest

Inherits:
Struct
  • Object
show all
Defined in:
gems/aws-sdk-lightsail/lib/aws-sdk-lightsail/types.rb

Overview

Note:

When making an API call, you may pass CreateInstancesFromSnapshotRequest data as a hash:

{
  instance_names: ["string"], # required
  attached_disk_mapping: {
    "ResourceName" => [
      {
        original_disk_path: "NonEmptyString",
        new_disk_name: "ResourceName",
      },
    ],
  },
  availability_zone: "string", # required
  instance_snapshot_name: "ResourceName",
  bundle_id: "NonEmptyString", # required
  user_data: "string",
  key_pair_name: "ResourceName",
  tags: [
    {
      key: "TagKey",
      value: "TagValue",
    },
  ],
  add_ons: [
    {
      add_on_type: "AutoSnapshot", # required, accepts AutoSnapshot
      auto_snapshot_add_on_request: {
        snapshot_time_of_day: "TimeOfDay",
      },
    },
  ],
  source_instance_name: "string",
  restore_date: "string",
  use_latest_restorable_auto_snapshot: false,
}

Constant Summary collapse

SENSITIVE =
[]

Instance Attribute Summary collapse

Instance Attribute Details

#add_onsArray<Types::AddOnRequest>

An array of objects representing the add-ons to enable for the new instance.

Returns:



2673
2674
2675
2676
2677
2678
2679
2680
2681
2682
2683
2684
2685
2686
2687
2688
# File 'gems/aws-sdk-lightsail/lib/aws-sdk-lightsail/types.rb', line 2673

class CreateInstancesFromSnapshotRequest < Struct.new(
  :instance_names,
  :attached_disk_mapping,
  :availability_zone,
  :instance_snapshot_name,
  :bundle_id,
  :user_data,
  :key_pair_name,
  :tags,
  :add_ons,
  :source_instance_name,
  :restore_date,
  :use_latest_restorable_auto_snapshot)
  SENSITIVE = []
  include Aws::Structure
end

#attached_disk_mappingHash<String,Array<Types::DiskMap>>

An object containing information about one or more disk mappings.

Returns:



2673
2674
2675
2676
2677
2678
2679
2680
2681
2682
2683
2684
2685
2686
2687
2688
# File 'gems/aws-sdk-lightsail/lib/aws-sdk-lightsail/types.rb', line 2673

class CreateInstancesFromSnapshotRequest < Struct.new(
  :instance_names,
  :attached_disk_mapping,
  :availability_zone,
  :instance_snapshot_name,
  :bundle_id,
  :user_data,
  :key_pair_name,
  :tags,
  :add_ons,
  :source_instance_name,
  :restore_date,
  :use_latest_restorable_auto_snapshot)
  SENSITIVE = []
  include Aws::Structure
end

#availability_zoneString

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.

Returns:

  • (String)


2673
2674
2675
2676
2677
2678
2679
2680
2681
2682
2683
2684
2685
2686
2687
2688
# File 'gems/aws-sdk-lightsail/lib/aws-sdk-lightsail/types.rb', line 2673

class CreateInstancesFromSnapshotRequest < Struct.new(
  :instance_names,
  :attached_disk_mapping,
  :availability_zone,
  :instance_snapshot_name,
  :bundle_id,
  :user_data,
  :key_pair_name,
  :tags,
  :add_ons,
  :source_instance_name,
  :restore_date,
  :use_latest_restorable_auto_snapshot)
  SENSITIVE = []
  include Aws::Structure
end

#bundle_idString

The bundle of specification information for your virtual private server (or instance), including the pricing plan (e.g., micro_1_0).

Returns:

  • (String)


2673
2674
2675
2676
2677
2678
2679
2680
2681
2682
2683
2684
2685
2686
2687
2688
# File 'gems/aws-sdk-lightsail/lib/aws-sdk-lightsail/types.rb', line 2673

class CreateInstancesFromSnapshotRequest < Struct.new(
  :instance_names,
  :attached_disk_mapping,
  :availability_zone,
  :instance_snapshot_name,
  :bundle_id,
  :user_data,
  :key_pair_name,
  :tags,
  :add_ons,
  :source_instance_name,
  :restore_date,
  :use_latest_restorable_auto_snapshot)
  SENSITIVE = []
  include Aws::Structure
end

#instance_namesArray<String>

The names for your new instances.

Returns:

  • (Array<String>)


2673
2674
2675
2676
2677
2678
2679
2680
2681
2682
2683
2684
2685
2686
2687
2688
# File 'gems/aws-sdk-lightsail/lib/aws-sdk-lightsail/types.rb', line 2673

class CreateInstancesFromSnapshotRequest < Struct.new(
  :instance_names,
  :attached_disk_mapping,
  :availability_zone,
  :instance_snapshot_name,
  :bundle_id,
  :user_data,
  :key_pair_name,
  :tags,
  :add_ons,
  :source_instance_name,
  :restore_date,
  :use_latest_restorable_auto_snapshot)
  SENSITIVE = []
  include Aws::Structure
end

#instance_snapshot_nameString

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. The instance snapshot name and source instance name parameters are mutually exclusive.

^

Returns:

  • (String)


2673
2674
2675
2676
2677
2678
2679
2680
2681
2682
2683
2684
2685
2686
2687
2688
# File 'gems/aws-sdk-lightsail/lib/aws-sdk-lightsail/types.rb', line 2673

class CreateInstancesFromSnapshotRequest < Struct.new(
  :instance_names,
  :attached_disk_mapping,
  :availability_zone,
  :instance_snapshot_name,
  :bundle_id,
  :user_data,
  :key_pair_name,
  :tags,
  :add_ons,
  :source_instance_name,
  :restore_date,
  :use_latest_restorable_auto_snapshot)
  SENSITIVE = []
  include Aws::Structure
end

#key_pair_nameString

The name for your key pair.

Returns:

  • (String)


2673
2674
2675
2676
2677
2678
2679
2680
2681
2682
2683
2684
2685
2686
2687
2688
# File 'gems/aws-sdk-lightsail/lib/aws-sdk-lightsail/types.rb', line 2673

class CreateInstancesFromSnapshotRequest < Struct.new(
  :instance_names,
  :attached_disk_mapping,
  :availability_zone,
  :instance_snapshot_name,
  :bundle_id,
  :user_data,
  :key_pair_name,
  :tags,
  :add_ons,
  :source_instance_name,
  :restore_date,
  :use_latest_restorable_auto_snapshot)
  SENSITIVE = []
  include Aws::Structure
end

#restore_dateString

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. The restore date and use 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 Lightsail Dev Guide.

Returns:

  • (String)


2673
2674
2675
2676
2677
2678
2679
2680
2681
2682
2683
2684
2685
2686
2687
2688
# File 'gems/aws-sdk-lightsail/lib/aws-sdk-lightsail/types.rb', line 2673

class CreateInstancesFromSnapshotRequest < Struct.new(
  :instance_names,
  :attached_disk_mapping,
  :availability_zone,
  :instance_snapshot_name,
  :bundle_id,
  :user_data,
  :key_pair_name,
  :tags,
  :add_ons,
  :source_instance_name,
  :restore_date,
  :use_latest_restorable_auto_snapshot)
  SENSITIVE = []
  include Aws::Structure
end

#source_instance_nameString

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. The source instance name and instance snapshot name parameters are mutually exclusive.

  • Define this parameter only when creating a new instance from an automatic snapshot. For more information, see the Lightsail Dev Guide.

Returns:

  • (String)


2673
2674
2675
2676
2677
2678
2679
2680
2681
2682
2683
2684
2685
2686
2687
2688
# File 'gems/aws-sdk-lightsail/lib/aws-sdk-lightsail/types.rb', line 2673

class CreateInstancesFromSnapshotRequest < Struct.new(
  :instance_names,
  :attached_disk_mapping,
  :availability_zone,
  :instance_snapshot_name,
  :bundle_id,
  :user_data,
  :key_pair_name,
  :tags,
  :add_ons,
  :source_instance_name,
  :restore_date,
  :use_latest_restorable_auto_snapshot)
  SENSITIVE = []
  include Aws::Structure
end

#tagsArray<Types::Tag>

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.

Returns:



2673
2674
2675
2676
2677
2678
2679
2680
2681
2682
2683
2684
2685
2686
2687
2688
# File 'gems/aws-sdk-lightsail/lib/aws-sdk-lightsail/types.rb', line 2673

class CreateInstancesFromSnapshotRequest < Struct.new(
  :instance_names,
  :attached_disk_mapping,
  :availability_zone,
  :instance_snapshot_name,
  :bundle_id,
  :user_data,
  :key_pair_name,
  :tags,
  :add_ons,
  :source_instance_name,
  :restore_date,
  :use_latest_restorable_auto_snapshot)
  SENSITIVE = []
  include Aws::Structure
end

#use_latest_restorable_auto_snapshotBoolean

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. The use latest restorable auto snapshot and restore date parameters are mutually exclusive.

  • Define this parameter only when creating a new instance from an automatic snapshot. For more information, see the Lightsail Dev Guide.

Returns:

  • (Boolean)


2673
2674
2675
2676
2677
2678
2679
2680
2681
2682
2683
2684
2685
2686
2687
2688
# File 'gems/aws-sdk-lightsail/lib/aws-sdk-lightsail/types.rb', line 2673

class CreateInstancesFromSnapshotRequest < Struct.new(
  :instance_names,
  :attached_disk_mapping,
  :availability_zone,
  :instance_snapshot_name,
  :bundle_id,
  :user_data,
  :key_pair_name,
  :tags,
  :add_ons,
  :source_instance_name,
  :restore_date,
  :use_latest_restorable_auto_snapshot)
  SENSITIVE = []
  include Aws::Structure
end

#user_dataString

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 Dev Guide.

Returns:

  • (String)


2673
2674
2675
2676
2677
2678
2679
2680
2681
2682
2683
2684
2685
2686
2687
2688
# File 'gems/aws-sdk-lightsail/lib/aws-sdk-lightsail/types.rb', line 2673

class CreateInstancesFromSnapshotRequest < Struct.new(
  :instance_names,
  :attached_disk_mapping,
  :availability_zone,
  :instance_snapshot_name,
  :bundle_id,
  :user_data,
  :key_pair_name,
  :tags,
  :add_ons,
  :source_instance_name,
  :restore_date,
  :use_latest_restorable_auto_snapshot)
  SENSITIVE = []
  include Aws::Structure
end