Skip to main content

network_migration_definitions

Creates, updates, deletes, gets or lists a network_migration_definitions resource.

Overview

Namenetwork_migration_definitions
TypeResource
Idaws.mgn.network_migration_definitions

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
namestringThe name of the network migration definition. (pattern: <code>[^\s\x00]( [^\s\x00])</code>)
arnstringThe Amazon Resource Name (ARN) of the network migration definition.
created_atstring (date-time)The timestamp when the network migration definition was created.
descriptionstringA description of the network migration definition. (pattern: <code>[^\x00]*</code>)
network_migration_definition_idstringThe unique identifier of the network migration definition. (pattern: <code>nmd-[0-9a-zA-Z]{17}</code>)
scope_tagsobjectScope tags for the network migration definition.
source_configurationsarrayA list of source configurations for the network migration.
tagsobjectTags assigned to the network migration definition.
target_deploymentstringThe target deployment configuration for the migrated network. (SINGLE_ACCOUNT, MULTI_ACCOUNT)
target_networkobjectConfiguration for the target network topology and addressing.
target_s3_configurationobjectS3 configuration for storing target network artifacts.
updated_atstring (date-time)The timestamp when the network migration definition was last updated.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
get_network_migration_definitionselectregionRetrieves the details of a network migration definition including source and target configurations.
list_network_migration_definitionsselectregionLists all network migration definitions in the account, with optional filtering.
create_network_migration_definitioninsertregion, name, targetS3Configuration, targetNetworkCreates a new network migration definition that specifies the source and target network configuration for a migration.
update_network_migration_definitionupdateregion, networkMigrationDefinitionIDUpdates an existing network migration definition with new source or target configurations.
delete_network_migration_definitiondeleteregionDeletes a network migration definition. This operation removes the migration definition and all associated metadata.
start_network_migration_analysisexecregion, networkMigrationExecutionID, networkMigrationDefinitionIDStarts a network migration analysis job to evaluate connectivity and compatibility of the migration mappings.
start_network_migration_code_generationexecregion, networkMigrationExecutionID, networkMigrationDefinitionIDStarts a code generation job to convert network migration mappings into infrastructure-as-code templates.
start_network_migration_deploymentexecregion, networkMigrationExecutionID, networkMigrationDefinitionIDStarts a deployment job to create the target network infrastructure based on the generated code templates.
start_network_migration_mappingexecregion, networkMigrationExecutionID, networkMigrationDefinitionIDStarts the network migration mapping process for a given network migration execution.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
regionstringAWS region (default: us-east-1)

SELECT examples

Retrieves the details of a network migration definition including source and target configurations.

SELECT
name,
arn,
created_at,
description,
network_migration_definition_id,
scope_tags,
source_configurations,
tags,
target_deployment,
target_network,
target_s3_configuration,
updated_at
FROM aws.mgn.network_migration_definitions
WHERE region = '{{ region }}' -- required
;

INSERT examples

Creates a new network migration definition that specifies the source and target network configuration for a migration.

INSERT INTO aws.mgn.network_migration_definitions (
name,
description,
sourceConfigurations,
targetS3Configuration,
targetNetwork,
targetDeployment,
tags,
scopeTags,
region
)
SELECT
'{{ name }}' /* required */,
'{{ description }}',
'{{ sourceConfigurations }}',
'{{ targetS3Configuration }}' /* required */,
'{{ targetNetwork }}' /* required */,
'{{ targetDeployment }}',
'{{ tags }}',
'{{ scopeTags }}',
'{{ region }}'
RETURNING
name,
arn,
created_at,
description,
network_migration_definition_id,
scope_tags,
source_configurations,
tags,
target_deployment,
target_network,
target_s3_configuration,
updated_at
;

UPDATE examples

Updates an existing network migration definition with new source or target configurations.

UPDATE aws.mgn.network_migration_definitions
SET
networkMigrationDefinitionID = '{{ networkMigrationDefinitionID }}',
name = '{{ name }}',
description = '{{ description }}',
sourceConfigurations = '{{ sourceConfigurations }}',
targetS3Configuration = '{{ targetS3Configuration }}',
targetNetwork = '{{ targetNetwork }}',
targetDeployment = '{{ targetDeployment }}',
scopeTags = '{{ scopeTags }}'
WHERE
region = '{{ region }}' --required
AND networkMigrationDefinitionID = '{{ networkMigrationDefinitionID }}' --required
RETURNING
name,
arn,
created_at,
description,
network_migration_definition_id,
scope_tags,
source_configurations,
tags,
target_deployment,
target_network,
target_s3_configuration,
updated_at;

DELETE examples

Deletes a network migration definition. This operation removes the migration definition and all associated metadata.

DELETE FROM aws.mgn.network_migration_definitions
WHERE region = '{{ region }}' --required
;

Lifecycle Methods

Starts a network migration analysis job to evaluate connectivity and compatibility of the migration mappings.

EXEC aws.mgn.network_migration_definitions.start_network_migration_analysis
@region='{{ region }}' --required
@@json=
'{
"networkMigrationExecutionID": "{{ networkMigrationExecutionID }}",
"networkMigrationDefinitionID": "{{ networkMigrationDefinitionID }}"
}'
;