create_service
async
¶
create_service(
name: ResourceName,
template_name: ResourceName,
template_major_version: TemplateVersionPart,
spec: SpecContents,
*,
config_overrides: Optional[AsyncProtonClientConfig] = None,
description: Optional[Description] = None,
template_minor_version: Optional[TemplateVersionPart] = None,
repository_connection_arn: Optional[Arn] = None,
repository_id: Optional[RepositoryId] = None,
branch_name: Optional[GitBranchName] = None,
tags: Optional[TagList] = None,
) -> CreateServiceOutput
Create an Proton service. An Proton service is an instantiation of a service template and often includes several service instances and pipeline. For more information, see Services in the Proton User Guide.
Parameters:
-
name(ResourceName) –The service name.
-
description(Optional[Description], default:None) –A description of the Proton service.
-
template_name(ResourceName) –The name of the service template that's used to create the service.
-
template_major_version(TemplateVersionPart) –The major version of the service template that was used to create the service.
-
template_minor_version(Optional[TemplateVersionPart], default:None) –The minor version of the service template that was used to create the service.
-
spec(SpecContents) –A link to a spec file that provides inputs as defined in the service template bundle schema file. The spec file is in YAML format. Don’t include pipeline inputs in the spec if your service template doesn’t include a service pipeline. For more information, see Create a service in the Proton User Guide.
-
repository_connection_arn(Optional[Arn], default:None) –The Amazon Resource Name (ARN) of the repository connection. For more information, see Setting up an AWS CodeStar connection in the Proton User Guide. Don't include this parameter if your service template doesn't include a service pipeline.
-
repository_id(Optional[RepositoryId], default:None) –The ID of the code repository. Don't include this parameter if your service template doesn't include a service pipeline.
-
branch_name(Optional[GitBranchName], default:None) –The name of the code repository branch that holds the code that's deployed in Proton. Don't include this parameter if your service template doesn't include a service pipeline.
-
tags(Optional[TagList], default:None) –An optional list of metadata items that you can associate with the Proton service. A tag is a key-value pair.
For more information, see Proton resources and tagging in the Proton User Guide.
Raises:
-
AccessDeniedException–There isn't sufficient access for performing this action.
-
ConflictException–The request couldn't be made due to a conflicting operation or resource.
-
InternalServerException–The request failed to register with the service.
-
ResourceNotFoundException–The requested resource wasn't found.
-
ServiceQuotaExceededException–A quota was exceeded. For more information, see Proton Quotas in the Proton User Guide.
-
ThrottlingException–The request was denied due to request throttling.
-
ValidationException–The input is invalid or an out-of-range value was supplied for the input parameter.
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_proton/_services/async_proton.py
5295 5296 5297 5298 5299 5300 5301 5302 5303 5304 5305 5306 5307 5308 5309 5310 5311 5312 5313 5314 5315 5316 5317 5318 5319 5320 5321 5322 5323 5324 5325 5326 5327 5328 5329 5330 5331 5332 5333 5334 5335 5336 5337 5338 5339 5340 5341 5342 5343 5344 5345 5346 5347 5348 5349 5350 5351 5352 5353 5354 5355 5356 5357 5358 5359 5360 5361 5362 5363 5364 5365 5366 5367 5368 5369 5370 5371 5372 5373 5374 5375 5376 5377 5378 5379 5380 5381 5382 5383 5384 5385 5386 5387 5388 5389 5390 5391 5392 5393 5394 5395 5396 5397 5398 5399 | |