create_network_migration_definition
async
¶
create_network_migration_definition(
name: NetworkMigrationDefinitionName,
target_s3_configuration: TargetS3Configuration,
target_network: TargetNetwork,
*,
config_overrides: Optional[AsyncmgnClientConfig] = None,
client_token: Optional[ClientIdempotencyToken] = None,
description: Optional[NetworkMigrationDefinitionDescription] = None,
source_configurations: Optional[SourceConfigurationList] = None,
definition_type: Optional[DefinitionType] = None,
target_deployment: Optional[TargetDeployment] = None,
vpc_provisioning_strategy: Optional[VpcProvisioningStrategy] = None,
cidr_mappings: Optional[CidrMappingsList] = None,
tags: Optional[TagsMap] = None,
scope_tags: Optional[ScopeTagsMap] = None,
) -> NetworkMigrationDefinition
Creates a new network migration definition that specifies the source and target network configuration for a migration.
Parameters:
-
client_token(Optional[ClientIdempotencyToken], default:None) –A unique, case-sensitive identifier that you provide to ensure the idempotency of the request.
-
name(NetworkMigrationDefinitionName) –The name of the network migration definition.
-
description(Optional[NetworkMigrationDefinitionDescription], default:None) –A description of the network migration definition.
-
source_configurations(Optional[SourceConfigurationList], default:None) –A list of source configurations for the network migration.
-
definition_type(Optional[DefinitionType], default:None) –Specifies the type of the definition.
MIGRATIONmigrates an existing network.NEW_NETWORKdesigns a new network. If you omit this value, the definition type isMIGRATION. -
target_s3_configuration(TargetS3Configuration) –The S3 configuration for storing the target network artifacts.
-
target_network(TargetNetwork) –The target network configuration including topology and CIDR ranges.
-
target_deployment(Optional[TargetDeployment], default:None) –The target deployment configuration for the migrated network.
-
vpc_provisioning_strategy(Optional[VpcProvisioningStrategy], default:None) –Specifies whether to create new target VPCs or use existing ones. Set to
CREATE_NEWto provision new target VPCs as part of the migration, orUSE_EXISTINGto migrate into existing VPCs in the target account. -
cidr_mappings(Optional[CidrMappingsList], default:None) –A list of CIDR mappings that map original source CIDR ranges to updated target CIDR ranges. CIDR mappings can be provided only when
vpcProvisioningStrategyis set toUSE_EXISTING. -
tags(Optional[TagsMap], default:None) –Tags to assign to the network migration definition.
-
scope_tags(Optional[ScopeTagsMap], default:None) –Scope tags for the network migration definition to control access and organization.
Raises:
-
ServiceQuotaExceededException–The request could not be completed because it exceeded the service quota.
-
ValidationException–Validate exception.
-
UnknownServiceError–The service returned an error code this client does not model.
Examples:
Sample CreateNetworkMigrationDefinition call
>>> await client.create_network_migration_definition(name='network1', description='network 1 description', target_deployment='SINGLE_ACCOUNT', source_configurations=[{'sourceEnvironment': 'NSX', 'sourceS3Configuration': {'s3Bucket': 'source_bucket', 's3Key': 'source_key', 's3BucketOwner': '012345678901'}}], target_s3_configuration={'s3Bucket': 'target_bucket', 's3BucketOwner': '012345678901'}, target_network={'topology': 'ISOLATED_VPC', 'inboundCidr': '192.168.1.0/24'})
Source code in docs_src/capo_mgn/_services/async_mgn.py
3212 3213 3214 3215 3216 3217 3218 3219 3220 3221 3222 3223 3224 3225 3226 3227 3228 3229 3230 3231 3232 3233 3234 3235 3236 3237 3238 3239 3240 3241 3242 3243 3244 3245 3246 3247 3248 3249 3250 3251 3252 3253 3254 3255 3256 3257 3258 3259 3260 3261 3262 3263 3264 3265 3266 3267 3268 3269 3270 3271 3272 3273 3274 3275 3276 3277 3278 3279 3280 3281 3282 3283 3284 3285 3286 3287 3288 3289 3290 3291 3292 3293 3294 3295 3296 3297 3298 3299 3300 3301 3302 3303 3304 3305 3306 3307 3308 3309 3310 3311 3312 3313 3314 3315 3316 3317 3318 3319 3320 3321 3322 3323 3324 3325 3326 3327 3328 3329 3330 3331 3332 3333 3334 3335 3336 3337 3338 3339 3340 | |