aws-sdk-ec2 1.0.0.rc2 → 1.0.0.rc3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/aws-sdk-ec2.rb +2 -2
- data/lib/aws-sdk-ec2/classic_address.rb +198 -200
- data/lib/aws-sdk-ec2/client.rb +17169 -14563
- data/lib/aws-sdk-ec2/client_api.rb +6458 -6301
- data/lib/aws-sdk-ec2/dhcp_options.rb +158 -160
- data/lib/aws-sdk-ec2/errors.rb +4 -13
- data/lib/aws-sdk-ec2/image.rb +404 -406
- data/lib/aws-sdk-ec2/instance.rb +1423 -1422
- data/lib/aws-sdk-ec2/internet_gateway.rb +178 -180
- data/lib/aws-sdk-ec2/key_pair.rb +98 -100
- data/lib/aws-sdk-ec2/key_pair_info.rb +102 -104
- data/lib/aws-sdk-ec2/network_acl.rb +326 -328
- data/lib/aws-sdk-ec2/network_interface.rb +428 -430
- data/lib/aws-sdk-ec2/network_interface_association.rb +126 -128
- data/lib/aws-sdk-ec2/placement_group.rb +400 -399
- data/lib/aws-sdk-ec2/resource.rb +2696 -2659
- data/lib/aws-sdk-ec2/route.rb +229 -231
- data/lib/aws-sdk-ec2/route_table.rb +243 -245
- data/lib/aws-sdk-ec2/route_table_association.rb +148 -150
- data/lib/aws-sdk-ec2/security_group.rb +515 -517
- data/lib/aws-sdk-ec2/snapshot.rb +431 -433
- data/lib/aws-sdk-ec2/subnet.rb +981 -977
- data/lib/aws-sdk-ec2/tag.rb +185 -187
- data/lib/aws-sdk-ec2/types.rb +24081 -20965
- data/lib/aws-sdk-ec2/volume.rb +513 -512
- data/lib/aws-sdk-ec2/vpc.rb +1671 -1649
- data/lib/aws-sdk-ec2/vpc_address.rb +189 -191
- data/lib/aws-sdk-ec2/vpc_peering_connection.rb +219 -221
- data/lib/aws-sdk-ec2/waiters.rb +1252 -1210
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 07163de11ef5213365aa653bc84227e45c9e8dd0
|
4
|
+
data.tar.gz: 2ad099627cc36035190e52746c3fd5612746e301
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 40e9acac824ed6fbddd590e09df5ffcdeecdc9f6fbcb4b3a02248a9e53e9713cfe901e583e536817f4e6e4ab2cee6fb0d57386e66a2d6900be3bc52a72ac7ace
|
7
|
+
data.tar.gz: c8a48061219ef257b6d2e3a5e07b26752140af8eaf6f1a418ab294b87b27deb5ab0c513ddf7f39bbc5f2845e1f48bdc9a55a8cedc530b12ae486915375fcd4b3
|
data/lib/aws-sdk-ec2.rb
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
# WARNING ABOUT GENERATED CODE
|
2
2
|
#
|
3
|
-
# This file is generated. See the contributing for
|
3
|
+
# This file is generated. See the contributing guide for more information:
|
4
4
|
# https://github.com/aws/aws-sdk-ruby/blob/master/CONTRIBUTING.md
|
5
5
|
#
|
6
6
|
# WARNING ABOUT GENERATED CODE
|
@@ -65,6 +65,6 @@ require_relative 'aws-sdk-ec2/customizations'
|
|
65
65
|
# @service
|
66
66
|
module Aws::EC2
|
67
67
|
|
68
|
-
GEM_VERSION = '1.0.0.
|
68
|
+
GEM_VERSION = '1.0.0.rc3'
|
69
69
|
|
70
70
|
end
|
@@ -1,227 +1,225 @@
|
|
1
1
|
# WARNING ABOUT GENERATED CODE
|
2
2
|
#
|
3
|
-
# This file is generated. See the contributing for
|
3
|
+
# This file is generated. See the contributing guide for more information:
|
4
4
|
# https://github.com/aws/aws-sdk-ruby/blob/master/CONTRIBUTING.md
|
5
5
|
#
|
6
6
|
# WARNING ABOUT GENERATED CODE
|
7
7
|
|
8
|
-
module Aws
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
end
|
8
|
+
module Aws::EC2
|
9
|
+
class ClassicAddress
|
10
|
+
|
11
|
+
extend Aws::Deprecations
|
12
|
+
|
13
|
+
# @overload def initialize(public_ip, options = {})
|
14
|
+
# @param [String] public_ip
|
15
|
+
# @option options [Client] :client
|
16
|
+
# @overload def initialize(options = {})
|
17
|
+
# @option options [required, String] :public_ip
|
18
|
+
# @option options [Client] :client
|
19
|
+
def initialize(*args)
|
20
|
+
options = Hash === args.last ? args.pop.dup : {}
|
21
|
+
@public_ip = extract_public_ip(args, options)
|
22
|
+
@data = options.delete(:data)
|
23
|
+
@client = options.delete(:client) || Client.new(options)
|
24
|
+
end
|
26
25
|
|
27
|
-
|
26
|
+
# @!group Read-Only Attributes
|
28
27
|
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
28
|
+
# @return [String]
|
29
|
+
def public_ip
|
30
|
+
@public_ip
|
31
|
+
end
|
33
32
|
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
33
|
+
# The ID of the instance that the address is associated with (if any).
|
34
|
+
# @return [String]
|
35
|
+
def instance_id
|
36
|
+
data.instance_id
|
37
|
+
end
|
39
38
|
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
39
|
+
# The ID representing the allocation of the address for use with
|
40
|
+
# EC2-VPC.
|
41
|
+
# @return [String]
|
42
|
+
def allocation_id
|
43
|
+
data.allocation_id
|
44
|
+
end
|
46
45
|
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
46
|
+
# The ID representing the association of the address with an instance in
|
47
|
+
# a VPC.
|
48
|
+
# @return [String]
|
49
|
+
def association_id
|
50
|
+
data.association_id
|
51
|
+
end
|
53
52
|
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
53
|
+
# Indicates whether this Elastic IP address is for use with instances in
|
54
|
+
# EC2-Classic (`standard`) or instances in a VPC (`vpc`).
|
55
|
+
# @return [String]
|
56
|
+
def domain
|
57
|
+
data.domain
|
58
|
+
end
|
60
59
|
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
60
|
+
# The ID of the network interface.
|
61
|
+
# @return [String]
|
62
|
+
def network_interface_id
|
63
|
+
data.network_interface_id
|
64
|
+
end
|
66
65
|
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
66
|
+
# The ID of the AWS account that owns the network interface.
|
67
|
+
# @return [String]
|
68
|
+
def network_interface_owner_id
|
69
|
+
data.network_interface_owner_id
|
70
|
+
end
|
72
71
|
|
73
|
-
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
|
72
|
+
# The private IP address associated with the Elastic IP address.
|
73
|
+
# @return [String]
|
74
|
+
def private_ip_address
|
75
|
+
data.private_ip_address
|
76
|
+
end
|
78
77
|
|
79
|
-
|
78
|
+
# @!endgroup
|
80
79
|
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
80
|
+
# @return [Client]
|
81
|
+
def client
|
82
|
+
@client
|
83
|
+
end
|
85
84
|
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
-
|
100
|
-
|
101
|
-
|
102
|
-
|
103
|
-
|
104
|
-
|
105
|
-
|
85
|
+
# Loads, or reloads {#data} for the current {ClassicAddress}.
|
86
|
+
# Returns `self` making it possible to chain methods.
|
87
|
+
#
|
88
|
+
# classic_address.reload.data
|
89
|
+
#
|
90
|
+
# @return [self]
|
91
|
+
def load
|
92
|
+
resp = @client.describe_addresses(public_ips: [@public_ip])
|
93
|
+
@data = resp.addresses[0]
|
94
|
+
self
|
95
|
+
end
|
96
|
+
alias :reload :load
|
97
|
+
|
98
|
+
# @return [Types::Address]
|
99
|
+
# Returns the data for this {ClassicAddress}. Calls
|
100
|
+
# {Client#describe_addresses} if {#data_loaded?} is `false`.
|
101
|
+
def data
|
102
|
+
load unless @data
|
103
|
+
@data
|
104
|
+
end
|
106
105
|
|
107
|
-
|
108
|
-
|
109
|
-
|
110
|
-
|
111
|
-
|
112
|
-
|
106
|
+
# @return [Boolean]
|
107
|
+
# Returns `true` if this resource is loaded. Accessing attributes or
|
108
|
+
# {#data} on an unloaded resource will trigger a call to {#load}.
|
109
|
+
def data_loaded?
|
110
|
+
!!@data
|
111
|
+
end
|
113
112
|
|
114
|
-
|
115
|
-
|
116
|
-
|
117
|
-
|
118
|
-
|
119
|
-
|
120
|
-
|
121
|
-
|
122
|
-
|
123
|
-
|
124
|
-
|
125
|
-
|
126
|
-
|
127
|
-
|
128
|
-
|
129
|
-
|
130
|
-
|
131
|
-
|
132
|
-
|
133
|
-
|
134
|
-
|
135
|
-
|
136
|
-
|
137
|
-
|
138
|
-
|
139
|
-
|
140
|
-
|
141
|
-
|
142
|
-
|
143
|
-
|
144
|
-
|
145
|
-
|
146
|
-
|
147
|
-
|
148
|
-
|
149
|
-
|
150
|
-
|
151
|
-
|
152
|
-
|
153
|
-
|
154
|
-
|
155
|
-
|
156
|
-
|
157
|
-
|
158
|
-
|
159
|
-
|
160
|
-
|
113
|
+
# @!group Actions
|
114
|
+
|
115
|
+
# @example Request syntax with placeholder values
|
116
|
+
#
|
117
|
+
# classic_address.associate({
|
118
|
+
# dry_run: false,
|
119
|
+
# instance_id: "String",
|
120
|
+
# allocation_id: "String",
|
121
|
+
# network_interface_id: "String",
|
122
|
+
# private_ip_address: "String",
|
123
|
+
# allow_reassociation: false,
|
124
|
+
# })
|
125
|
+
# @param [Hash] options ({})
|
126
|
+
# @option options [Boolean] :dry_run
|
127
|
+
# Checks whether you have the required permissions for the action,
|
128
|
+
# without actually making the request, and provides an error response.
|
129
|
+
# If you have the required permissions, the error response is
|
130
|
+
# `DryRunOperation`. Otherwise, it is `UnauthorizedOperation`.
|
131
|
+
# @option options [String] :instance_id
|
132
|
+
# The ID of the instance. This is required for EC2-Classic. For EC2-VPC,
|
133
|
+
# you can specify either the instance ID or the network interface ID,
|
134
|
+
# but not both. The operation fails if you specify an instance ID unless
|
135
|
+
# exactly one network interface is attached.
|
136
|
+
# @option options [String] :allocation_id
|
137
|
+
# \[EC2-VPC\] The allocation ID. This is required for EC2-VPC.
|
138
|
+
# @option options [String] :network_interface_id
|
139
|
+
# \[EC2-VPC\] The ID of the network interface. If the instance has more
|
140
|
+
# than one network interface, you must specify a network interface ID.
|
141
|
+
# @option options [String] :private_ip_address
|
142
|
+
# \[EC2-VPC\] The primary or secondary private IP address to associate
|
143
|
+
# with the Elastic IP address. If no private IP address is specified,
|
144
|
+
# the Elastic IP address is associated with the primary private IP
|
145
|
+
# address.
|
146
|
+
# @option options [Boolean] :allow_reassociation
|
147
|
+
# \[EC2-VPC\] For a VPC in an EC2-Classic account, specify true to allow
|
148
|
+
# an Elastic IP address that is already associated with an instance or
|
149
|
+
# network interface to be reassociated with the specified instance or
|
150
|
+
# network interface. Otherwise, the operation fails. In a VPC in an
|
151
|
+
# EC2-VPC-only account, reassociation is automatic, therefore you can
|
152
|
+
# specify false to ensure the operation fails if the Elastic IP address
|
153
|
+
# is already associated with another resource.
|
154
|
+
# @return [Types::AssociateAddressResult]
|
155
|
+
def associate(options = {})
|
156
|
+
options = options.merge(public_ip: @public_ip)
|
157
|
+
resp = @client.associate_address(options)
|
158
|
+
resp.data
|
159
|
+
end
|
161
160
|
|
162
|
-
|
163
|
-
|
164
|
-
|
165
|
-
|
166
|
-
|
167
|
-
|
168
|
-
|
169
|
-
|
170
|
-
|
171
|
-
|
172
|
-
|
173
|
-
|
174
|
-
|
175
|
-
|
176
|
-
|
177
|
-
|
178
|
-
|
179
|
-
|
180
|
-
|
181
|
-
|
161
|
+
# @example Request syntax with placeholder values
|
162
|
+
#
|
163
|
+
# classic_address.disassociate({
|
164
|
+
# dry_run: false,
|
165
|
+
# association_id: "String",
|
166
|
+
# })
|
167
|
+
# @param [Hash] options ({})
|
168
|
+
# @option options [Boolean] :dry_run
|
169
|
+
# Checks whether you have the required permissions for the action,
|
170
|
+
# without actually making the request, and provides an error response.
|
171
|
+
# If you have the required permissions, the error response is
|
172
|
+
# `DryRunOperation`. Otherwise, it is `UnauthorizedOperation`.
|
173
|
+
# @option options [String] :association_id
|
174
|
+
# \[EC2-VPC\] The association ID. Required for EC2-VPC.
|
175
|
+
# @return [EmptyStructure]
|
176
|
+
def disassociate(options = {})
|
177
|
+
options = options.merge(public_ip: data.public_ip)
|
178
|
+
resp = @client.disassociate_address(options)
|
179
|
+
resp.data
|
180
|
+
end
|
182
181
|
|
183
|
-
|
184
|
-
|
185
|
-
|
186
|
-
|
187
|
-
|
188
|
-
|
189
|
-
|
190
|
-
|
191
|
-
|
192
|
-
|
193
|
-
|
194
|
-
|
195
|
-
|
196
|
-
|
197
|
-
|
198
|
-
|
199
|
-
|
200
|
-
|
201
|
-
|
202
|
-
|
182
|
+
# @example Request syntax with placeholder values
|
183
|
+
#
|
184
|
+
# classic_address.release({
|
185
|
+
# dry_run: false,
|
186
|
+
# allocation_id: "String",
|
187
|
+
# })
|
188
|
+
# @param [Hash] options ({})
|
189
|
+
# @option options [Boolean] :dry_run
|
190
|
+
# Checks whether you have the required permissions for the action,
|
191
|
+
# without actually making the request, and provides an error response.
|
192
|
+
# If you have the required permissions, the error response is
|
193
|
+
# `DryRunOperation`. Otherwise, it is `UnauthorizedOperation`.
|
194
|
+
# @option options [String] :allocation_id
|
195
|
+
# \[EC2-VPC\] The allocation ID. Required for EC2-VPC.
|
196
|
+
# @return [EmptyStructure]
|
197
|
+
def release(options = {})
|
198
|
+
options = options.merge(public_ip: data.public_ip)
|
199
|
+
resp = @client.release_address(options)
|
200
|
+
resp.data
|
201
|
+
end
|
203
202
|
|
204
|
-
|
205
|
-
|
206
|
-
|
207
|
-
|
208
|
-
|
209
|
-
|
210
|
-
|
211
|
-
|
212
|
-
|
213
|
-
def extract_public_ip(args, options)
|
214
|
-
value = args[0] || options.delete(:public_ip)
|
215
|
-
case value
|
216
|
-
when String then value
|
217
|
-
when nil then raise ArgumentError, "missing required option :public_ip"
|
218
|
-
else
|
219
|
-
msg = "expected :public_ip to be a String, got #{value.class}"
|
220
|
-
raise ArgumentError, msg
|
221
|
-
end
|
222
|
-
end
|
203
|
+
# @deprecated
|
204
|
+
# @api private
|
205
|
+
def identifiers
|
206
|
+
{ public_ip: @public_ip }
|
207
|
+
end
|
208
|
+
deprecated(:identifiers)
|
209
|
+
|
210
|
+
private
|
223
211
|
|
224
|
-
|
212
|
+
def extract_public_ip(args, options)
|
213
|
+
value = args[0] || options.delete(:public_ip)
|
214
|
+
case value
|
215
|
+
when String then value
|
216
|
+
when nil then raise ArgumentError, "missing required option :public_ip"
|
217
|
+
else
|
218
|
+
msg = "expected :public_ip to be a String, got #{value.class}"
|
219
|
+
raise ArgumentError, msg
|
220
|
+
end
|
225
221
|
end
|
222
|
+
|
223
|
+
class Collection < Aws::Resources::Collection; end
|
226
224
|
end
|
227
225
|
end
|