create_instance_profile
async
¶
create_instance_profile(
*,
config_overrides: Optional[AsyncDatabaseMigrationServiceClientConfig] = None,
availability_zone: Optional[String] = None,
kms_key_arn: Optional[String] = None,
publicly_accessible: Optional[BooleanOptional] = None,
tags: Optional[TagList] = None,
network_type: Optional[String] = None,
instance_profile_name: Optional[String] = None,
description: Optional[String] = None,
subnet_group_identifier: Optional[String] = None,
vpc_security_groups: Optional[StringList] = None,
) -> CreateInstanceProfileResponse
Creates the instance profile using the specified parameters.
Required permissions: dms:CreateInstanceProfile. For more information, see Actions, resources, and condition keys for Database Migration Service.
Parameters:
-
availability_zone(Optional[String], default:None) –The Availability Zone where the instance profile will be created. The default value is a random, system-chosen Availability Zone in the Amazon Web Services Region where your data provider is created, for examplem
us-east-1d. -
kms_key_arn(Optional[String], default:None) –The Amazon Resource Name (ARN) of the KMS key that is used to encrypt the connection parameters for the instance profile.
If you don't specify a value for the
KmsKeyArnparameter, then DMS uses an Amazon Web Services owned encryption key to encrypt your resources. -
publicly_accessible(Optional[BooleanOptional], default:None) –Specifies the accessibility options for the instance profile. A value of
truerepresents an instance profile with a public IP address. A value offalserepresents an instance profile with a private IP address. The default value istrue. -
tags(Optional[TagList], default:None) –One or more tags to be assigned to the instance profile.
-
network_type(Optional[String], default:None) –Specifies the network type for the instance profile. A value of
IPV4represents an instance profile with IPv4 network type and only supports IPv4 addressing. A value ofIPV6represents an instance profile with IPv6 network type and only supports IPv6 addressing. A value ofDUALrepresents an instance profile with dual network type that supports IPv4 and IPv6 addressing. -
instance_profile_name(Optional[String], default:None) –A user-friendly name for the instance profile.
-
description(Optional[String], default:None) –A user-friendly description of the instance profile.
-
subnet_group_identifier(Optional[String], default:None) –A subnet group to associate with the instance profile.
-
vpc_security_groups(Optional[StringList], default:None) –Specifies the VPC security group names to be used with the instance profile. The VPC security group must work with the VPC containing the instance profile.
Raises:
-
AccessDeniedFault–DMS was denied access to the endpoint. Check that the role is correctly configured.
-
FailedDependencyFault–A dependency threw an exception.
-
InvalidResourceStateFault–The resource is in a state that prevents it from being used for database migration.
-
KMSKeyNotAccessibleFault–DMS cannot access the KMS key.
-
ResourceAlreadyExistsFault–The resource you are attempting to create already exists.
-
ResourceNotFoundFault–The resource could not be found.
-
ResourceQuotaExceededFault–The quota for this resource quota has been exceeded.
-
S3AccessDeniedFault–Insufficient privileges are preventing access to an Amazon S3 object.
-
S3ResourceNotFoundFault–A specified Amazon S3 bucket, bucket folder, or other object can't be found.
-
UnknownServiceError–The service returned an error code this client does not model.
Examples:
Create an instance profile The following example creates an instance profile.
>>> await client.create_instance_profile(instance_profile_name='example-instance-profile', description='Example instance profile for documentation', subnet_group_identifier='example-replication-subnet-group', vpc_security_groups=['sg-0123456789abcdef0'], kms_key_arn='arn:aws:kms:us-east-1:111122223333:key/a1b2c3d4-5678-90ab-cdef-EXAMPLE11111', network_type='IPV4', publicly_accessible=False)
Source code in docs_src/capo_database_migration_service/_services/async_database_migration_service.py
1385 1386 1387 1388 1389 1390 1391 1392 1393 1394 1395 1396 1397 1398 1399 1400 1401 1402 1403 1404 1405 1406 1407 1408 1409 1410 1411 1412 1413 1414 1415 1416 1417 1418 1419 1420 1421 1422 1423 1424 1425 1426 1427 1428 1429 1430 1431 1432 1433 1434 1435 1436 1437 1438 1439 1440 1441 1442 1443 1444 1445 1446 1447 1448 1449 1450 1451 1452 1453 1454 1455 1456 1457 1458 1459 1460 1461 1462 1463 1464 1465 1466 1467 1468 1469 1470 1471 1472 1473 1474 1475 1476 1477 1478 1479 1480 1481 1482 1483 1484 1485 1486 1487 1488 1489 1490 1491 | |