aws-sdk-ecs 1.103.0 → 1.105.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +10 -0
- data/VERSION +1 -1
- data/lib/aws-sdk-ecs/client.rb +258 -3
- data/lib/aws-sdk-ecs/client_api.rb +61 -0
- data/lib/aws-sdk-ecs/endpoint_parameters.rb +66 -0
- data/lib/aws-sdk-ecs/endpoint_provider.rb +111 -0
- data/lib/aws-sdk-ecs/endpoints.rb +771 -0
- data/lib/aws-sdk-ecs/plugins/endpoints.rb +176 -0
- data/lib/aws-sdk-ecs/types.rb +152 -0
- data/lib/aws-sdk-ecs.rb +5 -1
- metadata +8 -4
@@ -0,0 +1,176 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# WARNING ABOUT GENERATED CODE
|
4
|
+
#
|
5
|
+
# This file is generated. See the contributing guide for more information:
|
6
|
+
# https://github.com/aws/aws-sdk-ruby/blob/version-3/CONTRIBUTING.md
|
7
|
+
#
|
8
|
+
# WARNING ABOUT GENERATED CODE
|
9
|
+
|
10
|
+
|
11
|
+
module Aws::ECS
|
12
|
+
module Plugins
|
13
|
+
class Endpoints < Seahorse::Client::Plugin
|
14
|
+
option(
|
15
|
+
:endpoint_provider,
|
16
|
+
doc_type: 'Aws::ECS::EndpointProvider',
|
17
|
+
docstring: 'The endpoint provider used to resolve endpoints. Any '\
|
18
|
+
'object that responds to `#resolve_endpoint(parameters)` '\
|
19
|
+
'where `parameters` is a Struct similar to '\
|
20
|
+
'`Aws::ECS::EndpointParameters`'
|
21
|
+
) do |cfg|
|
22
|
+
Aws::ECS::EndpointProvider.new
|
23
|
+
end
|
24
|
+
|
25
|
+
# @api private
|
26
|
+
class Handler < Seahorse::Client::Handler
|
27
|
+
def call(context)
|
28
|
+
# If endpoint was discovered, do not resolve or apply the endpoint.
|
29
|
+
unless context[:discovered_endpoint]
|
30
|
+
params = parameters_for_operation(context)
|
31
|
+
endpoint = context.config.endpoint_provider.resolve_endpoint(params)
|
32
|
+
|
33
|
+
context.http_request.endpoint = endpoint.url
|
34
|
+
apply_endpoint_headers(context, endpoint.headers)
|
35
|
+
end
|
36
|
+
|
37
|
+
context[:endpoint_params] = params
|
38
|
+
context[:auth_scheme] =
|
39
|
+
Aws::Endpoints.resolve_auth_scheme(context, endpoint)
|
40
|
+
|
41
|
+
@handler.call(context)
|
42
|
+
end
|
43
|
+
|
44
|
+
private
|
45
|
+
|
46
|
+
def apply_endpoint_headers(context, headers)
|
47
|
+
headers.each do |key, values|
|
48
|
+
value = values
|
49
|
+
.compact
|
50
|
+
.map { |s| Seahorse::Util.escape_header_list_string(s.to_s) }
|
51
|
+
.join(',')
|
52
|
+
|
53
|
+
context.http_request.headers[key] = value
|
54
|
+
end
|
55
|
+
end
|
56
|
+
|
57
|
+
def parameters_for_operation(context)
|
58
|
+
case context.operation_name
|
59
|
+
when :create_capacity_provider
|
60
|
+
Aws::ECS::Endpoints::CreateCapacityProvider.build(context)
|
61
|
+
when :create_cluster
|
62
|
+
Aws::ECS::Endpoints::CreateCluster.build(context)
|
63
|
+
when :create_service
|
64
|
+
Aws::ECS::Endpoints::CreateService.build(context)
|
65
|
+
when :create_task_set
|
66
|
+
Aws::ECS::Endpoints::CreateTaskSet.build(context)
|
67
|
+
when :delete_account_setting
|
68
|
+
Aws::ECS::Endpoints::DeleteAccountSetting.build(context)
|
69
|
+
when :delete_attributes
|
70
|
+
Aws::ECS::Endpoints::DeleteAttributes.build(context)
|
71
|
+
when :delete_capacity_provider
|
72
|
+
Aws::ECS::Endpoints::DeleteCapacityProvider.build(context)
|
73
|
+
when :delete_cluster
|
74
|
+
Aws::ECS::Endpoints::DeleteCluster.build(context)
|
75
|
+
when :delete_service
|
76
|
+
Aws::ECS::Endpoints::DeleteService.build(context)
|
77
|
+
when :delete_task_set
|
78
|
+
Aws::ECS::Endpoints::DeleteTaskSet.build(context)
|
79
|
+
when :deregister_container_instance
|
80
|
+
Aws::ECS::Endpoints::DeregisterContainerInstance.build(context)
|
81
|
+
when :deregister_task_definition
|
82
|
+
Aws::ECS::Endpoints::DeregisterTaskDefinition.build(context)
|
83
|
+
when :describe_capacity_providers
|
84
|
+
Aws::ECS::Endpoints::DescribeCapacityProviders.build(context)
|
85
|
+
when :describe_clusters
|
86
|
+
Aws::ECS::Endpoints::DescribeClusters.build(context)
|
87
|
+
when :describe_container_instances
|
88
|
+
Aws::ECS::Endpoints::DescribeContainerInstances.build(context)
|
89
|
+
when :describe_services
|
90
|
+
Aws::ECS::Endpoints::DescribeServices.build(context)
|
91
|
+
when :describe_task_definition
|
92
|
+
Aws::ECS::Endpoints::DescribeTaskDefinition.build(context)
|
93
|
+
when :describe_task_sets
|
94
|
+
Aws::ECS::Endpoints::DescribeTaskSets.build(context)
|
95
|
+
when :describe_tasks
|
96
|
+
Aws::ECS::Endpoints::DescribeTasks.build(context)
|
97
|
+
when :discover_poll_endpoint
|
98
|
+
Aws::ECS::Endpoints::DiscoverPollEndpoint.build(context)
|
99
|
+
when :execute_command
|
100
|
+
Aws::ECS::Endpoints::ExecuteCommand.build(context)
|
101
|
+
when :get_task_protection
|
102
|
+
Aws::ECS::Endpoints::GetTaskProtection.build(context)
|
103
|
+
when :list_account_settings
|
104
|
+
Aws::ECS::Endpoints::ListAccountSettings.build(context)
|
105
|
+
when :list_attributes
|
106
|
+
Aws::ECS::Endpoints::ListAttributes.build(context)
|
107
|
+
when :list_clusters
|
108
|
+
Aws::ECS::Endpoints::ListClusters.build(context)
|
109
|
+
when :list_container_instances
|
110
|
+
Aws::ECS::Endpoints::ListContainerInstances.build(context)
|
111
|
+
when :list_services
|
112
|
+
Aws::ECS::Endpoints::ListServices.build(context)
|
113
|
+
when :list_tags_for_resource
|
114
|
+
Aws::ECS::Endpoints::ListTagsForResource.build(context)
|
115
|
+
when :list_task_definition_families
|
116
|
+
Aws::ECS::Endpoints::ListTaskDefinitionFamilies.build(context)
|
117
|
+
when :list_task_definitions
|
118
|
+
Aws::ECS::Endpoints::ListTaskDefinitions.build(context)
|
119
|
+
when :list_tasks
|
120
|
+
Aws::ECS::Endpoints::ListTasks.build(context)
|
121
|
+
when :put_account_setting
|
122
|
+
Aws::ECS::Endpoints::PutAccountSetting.build(context)
|
123
|
+
when :put_account_setting_default
|
124
|
+
Aws::ECS::Endpoints::PutAccountSettingDefault.build(context)
|
125
|
+
when :put_attributes
|
126
|
+
Aws::ECS::Endpoints::PutAttributes.build(context)
|
127
|
+
when :put_cluster_capacity_providers
|
128
|
+
Aws::ECS::Endpoints::PutClusterCapacityProviders.build(context)
|
129
|
+
when :register_container_instance
|
130
|
+
Aws::ECS::Endpoints::RegisterContainerInstance.build(context)
|
131
|
+
when :register_task_definition
|
132
|
+
Aws::ECS::Endpoints::RegisterTaskDefinition.build(context)
|
133
|
+
when :run_task
|
134
|
+
Aws::ECS::Endpoints::RunTask.build(context)
|
135
|
+
when :start_task
|
136
|
+
Aws::ECS::Endpoints::StartTask.build(context)
|
137
|
+
when :stop_task
|
138
|
+
Aws::ECS::Endpoints::StopTask.build(context)
|
139
|
+
when :submit_attachment_state_changes
|
140
|
+
Aws::ECS::Endpoints::SubmitAttachmentStateChanges.build(context)
|
141
|
+
when :submit_container_state_change
|
142
|
+
Aws::ECS::Endpoints::SubmitContainerStateChange.build(context)
|
143
|
+
when :submit_task_state_change
|
144
|
+
Aws::ECS::Endpoints::SubmitTaskStateChange.build(context)
|
145
|
+
when :tag_resource
|
146
|
+
Aws::ECS::Endpoints::TagResource.build(context)
|
147
|
+
when :untag_resource
|
148
|
+
Aws::ECS::Endpoints::UntagResource.build(context)
|
149
|
+
when :update_capacity_provider
|
150
|
+
Aws::ECS::Endpoints::UpdateCapacityProvider.build(context)
|
151
|
+
when :update_cluster
|
152
|
+
Aws::ECS::Endpoints::UpdateCluster.build(context)
|
153
|
+
when :update_cluster_settings
|
154
|
+
Aws::ECS::Endpoints::UpdateClusterSettings.build(context)
|
155
|
+
when :update_container_agent
|
156
|
+
Aws::ECS::Endpoints::UpdateContainerAgent.build(context)
|
157
|
+
when :update_container_instances_state
|
158
|
+
Aws::ECS::Endpoints::UpdateContainerInstancesState.build(context)
|
159
|
+
when :update_service
|
160
|
+
Aws::ECS::Endpoints::UpdateService.build(context)
|
161
|
+
when :update_service_primary_task_set
|
162
|
+
Aws::ECS::Endpoints::UpdateServicePrimaryTaskSet.build(context)
|
163
|
+
when :update_task_protection
|
164
|
+
Aws::ECS::Endpoints::UpdateTaskProtection.build(context)
|
165
|
+
when :update_task_set
|
166
|
+
Aws::ECS::Endpoints::UpdateTaskSet.build(context)
|
167
|
+
end
|
168
|
+
end
|
169
|
+
end
|
170
|
+
|
171
|
+
def add_handlers(handlers, _config)
|
172
|
+
handlers.add(Handler, step: :build, priority: 75)
|
173
|
+
end
|
174
|
+
end
|
175
|
+
end
|
176
|
+
end
|
data/lib/aws-sdk-ecs/types.rb
CHANGED
@@ -5346,6 +5346,58 @@ module Aws::ECS
|
|
5346
5346
|
include Aws::Structure
|
5347
5347
|
end
|
5348
5348
|
|
5349
|
+
# @note When making an API call, you may pass GetTaskProtectionRequest
|
5350
|
+
# data as a hash:
|
5351
|
+
#
|
5352
|
+
# {
|
5353
|
+
# cluster: "String", # required
|
5354
|
+
# tasks: ["String"],
|
5355
|
+
# }
|
5356
|
+
#
|
5357
|
+
# @!attribute [rw] cluster
|
5358
|
+
# The short name or full Amazon Resource Name (ARN) of the cluster
|
5359
|
+
# that hosts the service that the task sets exist in.
|
5360
|
+
# @return [String]
|
5361
|
+
#
|
5362
|
+
# @!attribute [rw] tasks
|
5363
|
+
# A list of up to 100 task IDs or full ARN entries.
|
5364
|
+
# @return [Array<String>]
|
5365
|
+
#
|
5366
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/ecs-2014-11-13/GetTaskProtectionRequest AWS API Documentation
|
5367
|
+
#
|
5368
|
+
class GetTaskProtectionRequest < Struct.new(
|
5369
|
+
:cluster,
|
5370
|
+
:tasks)
|
5371
|
+
SENSITIVE = []
|
5372
|
+
include Aws::Structure
|
5373
|
+
end
|
5374
|
+
|
5375
|
+
# @!attribute [rw] protected_tasks
|
5376
|
+
# A list of tasks with the following information.
|
5377
|
+
#
|
5378
|
+
# * `taskArn`\: The task ARN.
|
5379
|
+
#
|
5380
|
+
# * `protectionEnabled`\: The protection status of the task. If
|
5381
|
+
# scale-in protection is enabled for a task, the value is `true`.
|
5382
|
+
# Otherwise, it is `false`.
|
5383
|
+
#
|
5384
|
+
# * `expirationDate`\: The epoch time when protection for the task
|
5385
|
+
# will expire.
|
5386
|
+
# @return [Array<Types::ProtectedTask>]
|
5387
|
+
#
|
5388
|
+
# @!attribute [rw] failures
|
5389
|
+
# Any failures associated with the call.
|
5390
|
+
# @return [Array<Types::Failure>]
|
5391
|
+
#
|
5392
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/ecs-2014-11-13/GetTaskProtectionResponse AWS API Documentation
|
5393
|
+
#
|
5394
|
+
class GetTaskProtectionResponse < Struct.new(
|
5395
|
+
:protected_tasks,
|
5396
|
+
:failures)
|
5397
|
+
SENSITIVE = []
|
5398
|
+
include Aws::Structure
|
5399
|
+
end
|
5400
|
+
|
5349
5401
|
# An object representing a container health check. Health check
|
5350
5402
|
# parameters that are specified in a container definition override any
|
5351
5403
|
# Docker health checks that exist in the container image (such as those
|
@@ -7470,6 +7522,33 @@ module Aws::ECS
|
|
7470
7522
|
include Aws::Structure
|
7471
7523
|
end
|
7472
7524
|
|
7525
|
+
# An object representing the protection status details for a task. You
|
7526
|
+
# can set the protection status with the UpdateTaskProtection API and
|
7527
|
+
# get the status of tasks with the GetTaskProtection API.
|
7528
|
+
#
|
7529
|
+
# @!attribute [rw] task_arn
|
7530
|
+
# The task ARN.
|
7531
|
+
# @return [String]
|
7532
|
+
#
|
7533
|
+
# @!attribute [rw] protection_enabled
|
7534
|
+
# The protection status of the task. If scale-in protection is enabled
|
7535
|
+
# for a task, the value is `true`. Otherwise, it is `false`.
|
7536
|
+
# @return [Boolean]
|
7537
|
+
#
|
7538
|
+
# @!attribute [rw] expiration_date
|
7539
|
+
# The epoch time when protection for the task will expire.
|
7540
|
+
# @return [Time]
|
7541
|
+
#
|
7542
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/ecs-2014-11-13/ProtectedTask AWS API Documentation
|
7543
|
+
#
|
7544
|
+
class ProtectedTask < Struct.new(
|
7545
|
+
:task_arn,
|
7546
|
+
:protection_enabled,
|
7547
|
+
:expiration_date)
|
7548
|
+
SENSITIVE = []
|
7549
|
+
include Aws::Structure
|
7550
|
+
end
|
7551
|
+
|
7473
7552
|
# The configuration details for the App Mesh proxy.
|
7474
7553
|
#
|
7475
7554
|
# For tasks that use the EC2 launch type, the container instances
|
@@ -12310,6 +12389,79 @@ module Aws::ECS
|
|
12310
12389
|
include Aws::Structure
|
12311
12390
|
end
|
12312
12391
|
|
12392
|
+
# @note When making an API call, you may pass UpdateTaskProtectionRequest
|
12393
|
+
# data as a hash:
|
12394
|
+
#
|
12395
|
+
# {
|
12396
|
+
# cluster: "String", # required
|
12397
|
+
# tasks: ["String"], # required
|
12398
|
+
# protection_enabled: false, # required
|
12399
|
+
# expires_in_minutes: 1,
|
12400
|
+
# }
|
12401
|
+
#
|
12402
|
+
# @!attribute [rw] cluster
|
12403
|
+
# The short name or full Amazon Resource Name (ARN) of the cluster
|
12404
|
+
# that hosts the service that the task sets exist in.
|
12405
|
+
# @return [String]
|
12406
|
+
#
|
12407
|
+
# @!attribute [rw] tasks
|
12408
|
+
# A list of up to 10 task IDs or full ARN entries.
|
12409
|
+
# @return [Array<String>]
|
12410
|
+
#
|
12411
|
+
# @!attribute [rw] protection_enabled
|
12412
|
+
# Specify `true` to mark a task for protection and `false` to unset
|
12413
|
+
# protection, making it eligible for termination.
|
12414
|
+
# @return [Boolean]
|
12415
|
+
#
|
12416
|
+
# @!attribute [rw] expires_in_minutes
|
12417
|
+
# If you set `protectionEnabled` to `true`, you can specify the
|
12418
|
+
# duration for task protection in minutes. You can specify a value
|
12419
|
+
# from 1 minute to up to 2,880 minutes (48 hours). During this time,
|
12420
|
+
# your task will not be terminated by scale-in events from Service
|
12421
|
+
# Auto Scaling or deployments. After this time period lapses,
|
12422
|
+
# `protectionEnabled` will be reset to `false`.
|
12423
|
+
#
|
12424
|
+
# If you don’t specify the time, then the task is automatically
|
12425
|
+
# protected for 120 minutes (2 hours).
|
12426
|
+
# @return [Integer]
|
12427
|
+
#
|
12428
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/ecs-2014-11-13/UpdateTaskProtectionRequest AWS API Documentation
|
12429
|
+
#
|
12430
|
+
class UpdateTaskProtectionRequest < Struct.new(
|
12431
|
+
:cluster,
|
12432
|
+
:tasks,
|
12433
|
+
:protection_enabled,
|
12434
|
+
:expires_in_minutes)
|
12435
|
+
SENSITIVE = []
|
12436
|
+
include Aws::Structure
|
12437
|
+
end
|
12438
|
+
|
12439
|
+
# @!attribute [rw] protected_tasks
|
12440
|
+
# A list of tasks with the following information.
|
12441
|
+
#
|
12442
|
+
# * `taskArn`\: The task ARN.
|
12443
|
+
#
|
12444
|
+
# * `protectionEnabled`\: The protection status of the task. If
|
12445
|
+
# scale-in protection is enabled for a task, the value is `true`.
|
12446
|
+
# Otherwise, it is `false`.
|
12447
|
+
#
|
12448
|
+
# * `expirationDate`\: The epoch time when protection for the task
|
12449
|
+
# will expire.
|
12450
|
+
# @return [Array<Types::ProtectedTask>]
|
12451
|
+
#
|
12452
|
+
# @!attribute [rw] failures
|
12453
|
+
# Any failures associated with the call.
|
12454
|
+
# @return [Array<Types::Failure>]
|
12455
|
+
#
|
12456
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/ecs-2014-11-13/UpdateTaskProtectionResponse AWS API Documentation
|
12457
|
+
#
|
12458
|
+
class UpdateTaskProtectionResponse < Struct.new(
|
12459
|
+
:protected_tasks,
|
12460
|
+
:failures)
|
12461
|
+
SENSITIVE = []
|
12462
|
+
include Aws::Structure
|
12463
|
+
end
|
12464
|
+
|
12313
12465
|
# @note When making an API call, you may pass UpdateTaskSetRequest
|
12314
12466
|
# data as a hash:
|
12315
12467
|
#
|
data/lib/aws-sdk-ecs.rb
CHANGED
@@ -13,10 +13,14 @@ require 'aws-sigv4'
|
|
13
13
|
|
14
14
|
require_relative 'aws-sdk-ecs/types'
|
15
15
|
require_relative 'aws-sdk-ecs/client_api'
|
16
|
+
require_relative 'aws-sdk-ecs/plugins/endpoints.rb'
|
16
17
|
require_relative 'aws-sdk-ecs/client'
|
17
18
|
require_relative 'aws-sdk-ecs/errors'
|
18
19
|
require_relative 'aws-sdk-ecs/waiters'
|
19
20
|
require_relative 'aws-sdk-ecs/resource'
|
21
|
+
require_relative 'aws-sdk-ecs/endpoint_parameters'
|
22
|
+
require_relative 'aws-sdk-ecs/endpoint_provider'
|
23
|
+
require_relative 'aws-sdk-ecs/endpoints'
|
20
24
|
require_relative 'aws-sdk-ecs/customizations'
|
21
25
|
|
22
26
|
# This module provides support for Amazon EC2 Container Service. This module is available in the
|
@@ -49,6 +53,6 @@ require_relative 'aws-sdk-ecs/customizations'
|
|
49
53
|
# @!group service
|
50
54
|
module Aws::ECS
|
51
55
|
|
52
|
-
GEM_VERSION = '1.
|
56
|
+
GEM_VERSION = '1.105.0'
|
53
57
|
|
54
58
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: aws-sdk-ecs
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.105.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Amazon Web Services
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-10
|
11
|
+
date: 2022-11-10 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: aws-sdk-core
|
@@ -19,7 +19,7 @@ dependencies:
|
|
19
19
|
version: '3'
|
20
20
|
- - ">="
|
21
21
|
- !ruby/object:Gem::Version
|
22
|
-
version: 3.
|
22
|
+
version: 3.165.0
|
23
23
|
type: :runtime
|
24
24
|
prerelease: false
|
25
25
|
version_requirements: !ruby/object:Gem::Requirement
|
@@ -29,7 +29,7 @@ dependencies:
|
|
29
29
|
version: '3'
|
30
30
|
- - ">="
|
31
31
|
- !ruby/object:Gem::Version
|
32
|
-
version: 3.
|
32
|
+
version: 3.165.0
|
33
33
|
- !ruby/object:Gem::Dependency
|
34
34
|
name: aws-sigv4
|
35
35
|
requirement: !ruby/object:Gem::Requirement
|
@@ -59,7 +59,11 @@ files:
|
|
59
59
|
- lib/aws-sdk-ecs/client.rb
|
60
60
|
- lib/aws-sdk-ecs/client_api.rb
|
61
61
|
- lib/aws-sdk-ecs/customizations.rb
|
62
|
+
- lib/aws-sdk-ecs/endpoint_parameters.rb
|
63
|
+
- lib/aws-sdk-ecs/endpoint_provider.rb
|
64
|
+
- lib/aws-sdk-ecs/endpoints.rb
|
62
65
|
- lib/aws-sdk-ecs/errors.rb
|
66
|
+
- lib/aws-sdk-ecs/plugins/endpoints.rb
|
63
67
|
- lib/aws-sdk-ecs/resource.rb
|
64
68
|
- lib/aws-sdk-ecs/types.rb
|
65
69
|
- lib/aws-sdk-ecs/waiters.rb
|