cartography 0.104.0rc3__py3-none-any.whl → 0.106.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of cartography might be problematic. Click here for more details.
- cartography/_version.py +2 -2
- cartography/cli.py +104 -3
- cartography/client/aws/__init__.py +19 -0
- cartography/client/aws/ecr.py +51 -0
- cartography/client/core/tx.py +62 -0
- cartography/config.py +32 -0
- cartography/data/indexes.cypher +0 -37
- cartography/data/jobs/cleanup/aws_import_lambda_cleanup.json +1 -1
- cartography/driftdetect/cli.py +3 -2
- cartography/graph/cleanupbuilder.py +198 -41
- cartography/graph/job.py +42 -0
- cartography/graph/querybuilder.py +136 -2
- cartography/graph/statement.py +1 -1
- cartography/intel/airbyte/__init__.py +105 -0
- cartography/intel/airbyte/connections.py +120 -0
- cartography/intel/airbyte/destinations.py +81 -0
- cartography/intel/airbyte/organizations.py +59 -0
- cartography/intel/airbyte/sources.py +78 -0
- cartography/intel/airbyte/tags.py +64 -0
- cartography/intel/airbyte/users.py +106 -0
- cartography/intel/airbyte/util.py +122 -0
- cartography/intel/airbyte/workspaces.py +63 -0
- cartography/intel/aws/acm.py +124 -0
- cartography/intel/aws/cloudtrail.py +3 -38
- cartography/intel/aws/codebuild.py +132 -0
- cartography/intel/aws/ecr.py +8 -2
- cartography/intel/aws/ecs.py +228 -380
- cartography/intel/aws/efs.py +179 -11
- cartography/intel/aws/iam.py +1 -1
- cartography/intel/aws/identitycenter.py +14 -3
- cartography/intel/aws/inspector.py +96 -53
- cartography/intel/aws/lambda_function.py +1 -1
- cartography/intel/aws/rds.py +2 -1
- cartography/intel/aws/resources.py +4 -0
- cartography/intel/aws/s3.py +195 -4
- cartography/intel/aws/sqs.py +36 -90
- cartography/intel/entra/__init__.py +22 -0
- cartography/intel/entra/applications.py +366 -0
- cartography/intel/entra/groups.py +151 -0
- cartography/intel/entra/ou.py +21 -5
- cartography/intel/entra/users.py +84 -42
- cartography/intel/kubernetes/__init__.py +30 -14
- cartography/intel/kubernetes/clusters.py +86 -0
- cartography/intel/kubernetes/namespaces.py +59 -57
- cartography/intel/kubernetes/pods.py +140 -77
- cartography/intel/kubernetes/secrets.py +95 -45
- cartography/intel/kubernetes/services.py +131 -67
- cartography/intel/kubernetes/util.py +125 -14
- cartography/intel/scaleway/__init__.py +127 -0
- cartography/intel/scaleway/iam/__init__.py +0 -0
- cartography/intel/scaleway/iam/apikeys.py +71 -0
- cartography/intel/scaleway/iam/applications.py +71 -0
- cartography/intel/scaleway/iam/groups.py +71 -0
- cartography/intel/scaleway/iam/users.py +71 -0
- cartography/intel/scaleway/instances/__init__.py +0 -0
- cartography/intel/scaleway/instances/flexibleips.py +86 -0
- cartography/intel/scaleway/instances/instances.py +92 -0
- cartography/intel/scaleway/projects.py +79 -0
- cartography/intel/scaleway/storage/__init__.py +0 -0
- cartography/intel/scaleway/storage/snapshots.py +86 -0
- cartography/intel/scaleway/storage/volumes.py +84 -0
- cartography/intel/scaleway/utils.py +37 -0
- cartography/intel/trivy/__init__.py +161 -0
- cartography/intel/trivy/scanner.py +363 -0
- cartography/models/airbyte/__init__.py +0 -0
- cartography/models/airbyte/connection.py +138 -0
- cartography/models/airbyte/destination.py +75 -0
- cartography/models/airbyte/organization.py +19 -0
- cartography/models/airbyte/source.py +75 -0
- cartography/models/airbyte/stream.py +74 -0
- cartography/models/airbyte/tag.py +69 -0
- cartography/models/airbyte/user.py +111 -0
- cartography/models/airbyte/workspace.py +46 -0
- cartography/models/aws/acm/__init__.py +0 -0
- cartography/models/aws/acm/certificate.py +75 -0
- cartography/models/aws/cloudtrail/trail.py +24 -0
- cartography/models/aws/codebuild/__init__.py +0 -0
- cartography/models/aws/codebuild/project.py +49 -0
- cartography/models/aws/ecs/__init__.py +0 -0
- cartography/models/aws/ecs/clusters.py +64 -0
- cartography/models/aws/ecs/container_definitions.py +93 -0
- cartography/models/aws/ecs/container_instances.py +84 -0
- cartography/models/aws/ecs/containers.py +99 -0
- cartography/models/aws/ecs/services.py +117 -0
- cartography/models/aws/ecs/task_definitions.py +135 -0
- cartography/models/aws/ecs/tasks.py +110 -0
- cartography/models/aws/efs/access_point.py +77 -0
- cartography/models/aws/efs/file_system.py +60 -0
- cartography/models/aws/efs/mount_target.py +29 -2
- cartography/models/aws/s3/notification.py +24 -0
- cartography/models/aws/secretsmanager/secret_version.py +0 -2
- cartography/models/aws/sqs/__init__.py +0 -0
- cartography/models/aws/sqs/queue.py +89 -0
- cartography/models/core/common.py +1 -0
- cartography/models/core/nodes.py +15 -2
- cartography/models/core/relationships.py +44 -0
- cartography/models/entra/app_role_assignment.py +115 -0
- cartography/models/entra/application.py +47 -0
- cartography/models/entra/group.py +91 -0
- cartography/models/entra/user.py +17 -51
- cartography/models/kubernetes/__init__.py +0 -0
- cartography/models/kubernetes/clusters.py +26 -0
- cartography/models/kubernetes/containers.py +108 -0
- cartography/models/kubernetes/namespaces.py +51 -0
- cartography/models/kubernetes/pods.py +80 -0
- cartography/models/kubernetes/secrets.py +79 -0
- cartography/models/kubernetes/services.py +108 -0
- cartography/models/scaleway/__init__.py +0 -0
- cartography/models/scaleway/iam/__init__.py +0 -0
- cartography/models/scaleway/iam/apikey.py +96 -0
- cartography/models/scaleway/iam/application.py +52 -0
- cartography/models/scaleway/iam/group.py +95 -0
- cartography/models/scaleway/iam/user.py +60 -0
- cartography/models/scaleway/instance/__init__.py +0 -0
- cartography/models/scaleway/instance/flexibleip.py +52 -0
- cartography/models/scaleway/instance/instance.py +118 -0
- cartography/models/scaleway/organization.py +19 -0
- cartography/models/scaleway/project.py +48 -0
- cartography/models/scaleway/storage/__init__.py +0 -0
- cartography/models/scaleway/storage/snapshot.py +78 -0
- cartography/models/scaleway/storage/volume.py +51 -0
- cartography/models/trivy/__init__.py +0 -0
- cartography/models/trivy/findings.py +66 -0
- cartography/models/trivy/fix.py +66 -0
- cartography/models/trivy/package.py +71 -0
- cartography/sync.py +10 -4
- cartography/util.py +15 -10
- {cartography-0.104.0rc3.dist-info → cartography-0.106.0.dist-info}/METADATA +6 -2
- {cartography-0.104.0rc3.dist-info → cartography-0.106.0.dist-info}/RECORD +133 -49
- cartography/data/jobs/cleanup/kubernetes_import_cleanup.json +0 -70
- {cartography-0.104.0rc3.dist-info → cartography-0.106.0.dist-info}/WHEEL +0 -0
- {cartography-0.104.0rc3.dist-info → cartography-0.106.0.dist-info}/entry_points.txt +0 -0
- {cartography-0.104.0rc3.dist-info → cartography-0.106.0.dist-info}/licenses/LICENSE +0 -0
- {cartography-0.104.0rc3.dist-info → cartography-0.106.0.dist-info}/top_level.txt +0 -0
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
from dataclasses import dataclass
|
|
2
|
+
|
|
3
|
+
from cartography.models.core.common import PropertyRef
|
|
4
|
+
from cartography.models.core.nodes import CartographyNodeProperties
|
|
5
|
+
from cartography.models.core.nodes import CartographyNodeSchema
|
|
6
|
+
from cartography.models.core.relationships import CartographyRelProperties
|
|
7
|
+
from cartography.models.core.relationships import CartographyRelSchema
|
|
8
|
+
from cartography.models.core.relationships import LinkDirection
|
|
9
|
+
from cartography.models.core.relationships import make_target_node_matcher
|
|
10
|
+
from cartography.models.core.relationships import OtherRelationships
|
|
11
|
+
from cartography.models.core.relationships import TargetNodeMatcher
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
@dataclass(frozen=True)
|
|
15
|
+
class ECSContainerInstanceNodeProperties(CartographyNodeProperties):
|
|
16
|
+
id: PropertyRef = PropertyRef("containerInstanceArn")
|
|
17
|
+
arn: PropertyRef = PropertyRef("containerInstanceArn", extra_index=True)
|
|
18
|
+
ec2_instance_id: PropertyRef = PropertyRef("ec2InstanceId")
|
|
19
|
+
capacity_provider_name: PropertyRef = PropertyRef("capacityProviderName")
|
|
20
|
+
version: PropertyRef = PropertyRef("version")
|
|
21
|
+
version_info_agent_version: PropertyRef = PropertyRef("versionInfo.agentVersion")
|
|
22
|
+
version_info_agent_hash: PropertyRef = PropertyRef("versionInfo.agentHash")
|
|
23
|
+
version_info_agent_docker_version: PropertyRef = PropertyRef(
|
|
24
|
+
"versionInfo.dockerVersion"
|
|
25
|
+
)
|
|
26
|
+
status: PropertyRef = PropertyRef("status")
|
|
27
|
+
status_reason: PropertyRef = PropertyRef("statusReason")
|
|
28
|
+
agent_connected: PropertyRef = PropertyRef("agentConnected")
|
|
29
|
+
agent_update_status: PropertyRef = PropertyRef("agentUpdateStatus")
|
|
30
|
+
registered_at: PropertyRef = PropertyRef("registeredAt")
|
|
31
|
+
region: PropertyRef = PropertyRef("Region", set_in_kwargs=True)
|
|
32
|
+
lastupdated: PropertyRef = PropertyRef("lastupdated", set_in_kwargs=True)
|
|
33
|
+
|
|
34
|
+
|
|
35
|
+
@dataclass(frozen=True)
|
|
36
|
+
class ECSContainerInstanceToAWSAccountRelProperties(CartographyRelProperties):
|
|
37
|
+
lastupdated: PropertyRef = PropertyRef("lastupdated", set_in_kwargs=True)
|
|
38
|
+
|
|
39
|
+
|
|
40
|
+
@dataclass(frozen=True)
|
|
41
|
+
class ECSContainerInstanceToAWSAccountRel(CartographyRelSchema):
|
|
42
|
+
target_node_label: str = "AWSAccount"
|
|
43
|
+
target_node_matcher: TargetNodeMatcher = make_target_node_matcher(
|
|
44
|
+
{"id": PropertyRef("AWS_ID", set_in_kwargs=True)}
|
|
45
|
+
)
|
|
46
|
+
direction: LinkDirection = LinkDirection.INWARD
|
|
47
|
+
rel_label: str = "RESOURCE"
|
|
48
|
+
properties: ECSContainerInstanceToAWSAccountRelProperties = (
|
|
49
|
+
ECSContainerInstanceToAWSAccountRelProperties()
|
|
50
|
+
)
|
|
51
|
+
|
|
52
|
+
|
|
53
|
+
@dataclass(frozen=True)
|
|
54
|
+
class ECSContainerInstanceToECSClusterRelProperties(CartographyRelProperties):
|
|
55
|
+
lastupdated: PropertyRef = PropertyRef("lastupdated", set_in_kwargs=True)
|
|
56
|
+
|
|
57
|
+
|
|
58
|
+
@dataclass(frozen=True)
|
|
59
|
+
class ECSContainerInstanceToECSClusterRel(CartographyRelSchema):
|
|
60
|
+
target_node_label: str = "ECSCluster"
|
|
61
|
+
target_node_matcher: TargetNodeMatcher = make_target_node_matcher(
|
|
62
|
+
{"id": PropertyRef("ClusterArn", set_in_kwargs=True)}
|
|
63
|
+
)
|
|
64
|
+
direction: LinkDirection = LinkDirection.INWARD
|
|
65
|
+
rel_label: str = "HAS_CONTAINER_INSTANCE"
|
|
66
|
+
properties: ECSContainerInstanceToECSClusterRelProperties = (
|
|
67
|
+
ECSContainerInstanceToECSClusterRelProperties()
|
|
68
|
+
)
|
|
69
|
+
|
|
70
|
+
|
|
71
|
+
@dataclass(frozen=True)
|
|
72
|
+
class ECSContainerInstanceSchema(CartographyNodeSchema):
|
|
73
|
+
label: str = "ECSContainerInstance"
|
|
74
|
+
properties: ECSContainerInstanceNodeProperties = (
|
|
75
|
+
ECSContainerInstanceNodeProperties()
|
|
76
|
+
)
|
|
77
|
+
sub_resource_relationship: ECSContainerInstanceToAWSAccountRel = (
|
|
78
|
+
ECSContainerInstanceToAWSAccountRel()
|
|
79
|
+
)
|
|
80
|
+
other_relationships: OtherRelationships = OtherRelationships(
|
|
81
|
+
[
|
|
82
|
+
ECSContainerInstanceToECSClusterRel(),
|
|
83
|
+
]
|
|
84
|
+
)
|
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
from dataclasses import dataclass
|
|
2
|
+
|
|
3
|
+
from cartography.models.core.common import PropertyRef
|
|
4
|
+
from cartography.models.core.nodes import CartographyNodeProperties
|
|
5
|
+
from cartography.models.core.nodes import CartographyNodeSchema
|
|
6
|
+
from cartography.models.core.relationships import CartographyRelProperties
|
|
7
|
+
from cartography.models.core.relationships import CartographyRelSchema
|
|
8
|
+
from cartography.models.core.relationships import LinkDirection
|
|
9
|
+
from cartography.models.core.relationships import make_target_node_matcher
|
|
10
|
+
from cartography.models.core.relationships import OtherRelationships
|
|
11
|
+
from cartography.models.core.relationships import TargetNodeMatcher
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
@dataclass(frozen=True)
|
|
15
|
+
class ECSContainerNodeProperties(CartographyNodeProperties):
|
|
16
|
+
id: PropertyRef = PropertyRef("containerArn")
|
|
17
|
+
arn: PropertyRef = PropertyRef("containerArn", extra_index=True)
|
|
18
|
+
task_arn: PropertyRef = PropertyRef("taskArn")
|
|
19
|
+
name: PropertyRef = PropertyRef("name")
|
|
20
|
+
image: PropertyRef = PropertyRef("image")
|
|
21
|
+
image_digest: PropertyRef = PropertyRef("imageDigest")
|
|
22
|
+
runtime_id: PropertyRef = PropertyRef("runtimeId")
|
|
23
|
+
last_status: PropertyRef = PropertyRef("lastStatus")
|
|
24
|
+
exit_code: PropertyRef = PropertyRef("exitCode")
|
|
25
|
+
reason: PropertyRef = PropertyRef("reason")
|
|
26
|
+
health_status: PropertyRef = PropertyRef("healthStatus")
|
|
27
|
+
cpu: PropertyRef = PropertyRef("cpu")
|
|
28
|
+
memory: PropertyRef = PropertyRef("memory")
|
|
29
|
+
memory_reservation: PropertyRef = PropertyRef("memoryReservation")
|
|
30
|
+
gpu_ids: PropertyRef = PropertyRef("gpuIds")
|
|
31
|
+
region: PropertyRef = PropertyRef("Region", set_in_kwargs=True)
|
|
32
|
+
lastupdated: PropertyRef = PropertyRef("lastupdated", set_in_kwargs=True)
|
|
33
|
+
|
|
34
|
+
|
|
35
|
+
@dataclass(frozen=True)
|
|
36
|
+
class ECSContainerToAWSAccountRelProperties(CartographyRelProperties):
|
|
37
|
+
lastupdated: PropertyRef = PropertyRef("lastupdated", set_in_kwargs=True)
|
|
38
|
+
|
|
39
|
+
|
|
40
|
+
@dataclass(frozen=True)
|
|
41
|
+
class ECSContainerToAWSAccountRel(CartographyRelSchema):
|
|
42
|
+
target_node_label: str = "AWSAccount"
|
|
43
|
+
target_node_matcher: TargetNodeMatcher = make_target_node_matcher(
|
|
44
|
+
{"id": PropertyRef("AWS_ID", set_in_kwargs=True)}
|
|
45
|
+
)
|
|
46
|
+
direction: LinkDirection = LinkDirection.INWARD
|
|
47
|
+
rel_label: str = "RESOURCE"
|
|
48
|
+
properties: ECSContainerToAWSAccountRelProperties = (
|
|
49
|
+
ECSContainerToAWSAccountRelProperties()
|
|
50
|
+
)
|
|
51
|
+
|
|
52
|
+
|
|
53
|
+
@dataclass(frozen=True)
|
|
54
|
+
class ECSContainerToTaskRelProperties(CartographyRelProperties):
|
|
55
|
+
lastupdated: PropertyRef = PropertyRef("lastupdated", set_in_kwargs=True)
|
|
56
|
+
|
|
57
|
+
|
|
58
|
+
@dataclass(frozen=True)
|
|
59
|
+
class ECSContainerToTaskRel(CartographyRelSchema):
|
|
60
|
+
target_node_label: str = "ECSTask"
|
|
61
|
+
target_node_matcher: TargetNodeMatcher = make_target_node_matcher(
|
|
62
|
+
{"id": PropertyRef("taskArn")}
|
|
63
|
+
)
|
|
64
|
+
direction: LinkDirection = LinkDirection.INWARD
|
|
65
|
+
rel_label: str = "HAS_CONTAINER"
|
|
66
|
+
properties: ECSContainerToTaskRelProperties = ECSContainerToTaskRelProperties()
|
|
67
|
+
|
|
68
|
+
|
|
69
|
+
@dataclass(frozen=True)
|
|
70
|
+
class ECSContainerToECRImageRelProperties(CartographyRelProperties):
|
|
71
|
+
lastupdated: PropertyRef = PropertyRef("lastupdated", set_in_kwargs=True)
|
|
72
|
+
|
|
73
|
+
|
|
74
|
+
@dataclass(frozen=True)
|
|
75
|
+
class ECSContainerToECRImageRel(CartographyRelSchema):
|
|
76
|
+
target_node_label: str = "ECRImage"
|
|
77
|
+
target_node_matcher: TargetNodeMatcher = make_target_node_matcher(
|
|
78
|
+
{"digest": PropertyRef("imageDigest")}
|
|
79
|
+
)
|
|
80
|
+
direction: LinkDirection = LinkDirection.OUTWARD
|
|
81
|
+
rel_label: str = "HAS_IMAGE"
|
|
82
|
+
properties: ECSContainerToECRImageRelProperties = (
|
|
83
|
+
ECSContainerToECRImageRelProperties()
|
|
84
|
+
)
|
|
85
|
+
|
|
86
|
+
|
|
87
|
+
@dataclass(frozen=True)
|
|
88
|
+
class ECSContainerSchema(CartographyNodeSchema):
|
|
89
|
+
label: str = "ECSContainer"
|
|
90
|
+
properties: ECSContainerNodeProperties = ECSContainerNodeProperties()
|
|
91
|
+
sub_resource_relationship: ECSContainerToAWSAccountRel = (
|
|
92
|
+
ECSContainerToAWSAccountRel()
|
|
93
|
+
)
|
|
94
|
+
other_relationships: OtherRelationships = OtherRelationships(
|
|
95
|
+
[
|
|
96
|
+
ECSContainerToTaskRel(),
|
|
97
|
+
ECSContainerToECRImageRel(),
|
|
98
|
+
]
|
|
99
|
+
)
|
|
@@ -0,0 +1,117 @@
|
|
|
1
|
+
from dataclasses import dataclass
|
|
2
|
+
|
|
3
|
+
from cartography.models.core.common import PropertyRef
|
|
4
|
+
from cartography.models.core.nodes import CartographyNodeProperties
|
|
5
|
+
from cartography.models.core.nodes import CartographyNodeSchema
|
|
6
|
+
from cartography.models.core.relationships import CartographyRelProperties
|
|
7
|
+
from cartography.models.core.relationships import CartographyRelSchema
|
|
8
|
+
from cartography.models.core.relationships import LinkDirection
|
|
9
|
+
from cartography.models.core.relationships import make_target_node_matcher
|
|
10
|
+
from cartography.models.core.relationships import OtherRelationships
|
|
11
|
+
from cartography.models.core.relationships import TargetNodeMatcher
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
@dataclass(frozen=True)
|
|
15
|
+
class ECSServiceNodeProperties(CartographyNodeProperties):
|
|
16
|
+
id: PropertyRef = PropertyRef("serviceArn")
|
|
17
|
+
arn: PropertyRef = PropertyRef("serviceArn", extra_index=True)
|
|
18
|
+
name: PropertyRef = PropertyRef("serviceName")
|
|
19
|
+
cluster_arn: PropertyRef = PropertyRef("clusterArn")
|
|
20
|
+
status: PropertyRef = PropertyRef("status")
|
|
21
|
+
desired_count: PropertyRef = PropertyRef("desiredCount")
|
|
22
|
+
running_count: PropertyRef = PropertyRef("runningCount")
|
|
23
|
+
pending_count: PropertyRef = PropertyRef("pendingCount")
|
|
24
|
+
launch_type: PropertyRef = PropertyRef("launchType")
|
|
25
|
+
platform_version: PropertyRef = PropertyRef("platformVersion")
|
|
26
|
+
platform_family: PropertyRef = PropertyRef("platformFamily")
|
|
27
|
+
task_definition: PropertyRef = PropertyRef("taskDefinition")
|
|
28
|
+
deployment_config_circuit_breaker_enable: PropertyRef = PropertyRef(
|
|
29
|
+
"deploymentConfiguration.deploymentCircuitBreaker.enable"
|
|
30
|
+
)
|
|
31
|
+
deployment_config_circuit_breaker_rollback: PropertyRef = PropertyRef(
|
|
32
|
+
"deploymentConfiguration.deploymentCircuitBreaker.rollback"
|
|
33
|
+
)
|
|
34
|
+
deployment_config_maximum_percent: PropertyRef = PropertyRef(
|
|
35
|
+
"deploymentConfiguration.maximumPercent"
|
|
36
|
+
)
|
|
37
|
+
deployment_config_minimum_healthy_percent: PropertyRef = PropertyRef(
|
|
38
|
+
"deploymentConfiguration.minimumHealthyPercent"
|
|
39
|
+
)
|
|
40
|
+
role_arn: PropertyRef = PropertyRef("roleArn")
|
|
41
|
+
created_at: PropertyRef = PropertyRef("createdAt")
|
|
42
|
+
health_check_grace_period_seconds: PropertyRef = PropertyRef(
|
|
43
|
+
"healthCheckGracePeriodSeconds"
|
|
44
|
+
)
|
|
45
|
+
created_by: PropertyRef = PropertyRef("createdBy")
|
|
46
|
+
enable_ecs_managed_tags: PropertyRef = PropertyRef("enableECSManagedTags")
|
|
47
|
+
propagate_tags: PropertyRef = PropertyRef("propagateTags")
|
|
48
|
+
enable_execute_command: PropertyRef = PropertyRef("enableExecuteCommand")
|
|
49
|
+
region: PropertyRef = PropertyRef("Region", set_in_kwargs=True)
|
|
50
|
+
lastupdated: PropertyRef = PropertyRef("lastupdated", set_in_kwargs=True)
|
|
51
|
+
|
|
52
|
+
|
|
53
|
+
@dataclass(frozen=True)
|
|
54
|
+
class ECSServiceToECSClusterRelProperties(CartographyRelProperties):
|
|
55
|
+
lastupdated: PropertyRef = PropertyRef("lastupdated", set_in_kwargs=True)
|
|
56
|
+
|
|
57
|
+
|
|
58
|
+
@dataclass(frozen=True)
|
|
59
|
+
class ECSServiceToECSClusterRel(CartographyRelSchema):
|
|
60
|
+
target_node_label: str = "ECSCluster"
|
|
61
|
+
target_node_matcher: TargetNodeMatcher = make_target_node_matcher(
|
|
62
|
+
{"id": PropertyRef("ClusterArn", set_in_kwargs=True)}
|
|
63
|
+
)
|
|
64
|
+
direction: LinkDirection = LinkDirection.INWARD
|
|
65
|
+
rel_label: str = "HAS_SERVICE"
|
|
66
|
+
properties: ECSServiceToECSClusterRelProperties = (
|
|
67
|
+
ECSServiceToECSClusterRelProperties()
|
|
68
|
+
)
|
|
69
|
+
|
|
70
|
+
|
|
71
|
+
@dataclass(frozen=True)
|
|
72
|
+
class ECSServiceToTaskDefinitionRelProperties(CartographyRelProperties):
|
|
73
|
+
lastupdated: PropertyRef = PropertyRef("lastupdated", set_in_kwargs=True)
|
|
74
|
+
|
|
75
|
+
|
|
76
|
+
@dataclass(frozen=True)
|
|
77
|
+
class ECSServiceToTaskDefinitionRel(CartographyRelSchema):
|
|
78
|
+
target_node_label: str = "ECSTaskDefinition"
|
|
79
|
+
target_node_matcher: TargetNodeMatcher = make_target_node_matcher(
|
|
80
|
+
{"id": PropertyRef("taskDefinition")}
|
|
81
|
+
)
|
|
82
|
+
direction: LinkDirection = LinkDirection.OUTWARD
|
|
83
|
+
rel_label: str = "HAS_TASK_DEFINITION"
|
|
84
|
+
properties: ECSServiceToTaskDefinitionRelProperties = (
|
|
85
|
+
ECSServiceToTaskDefinitionRelProperties()
|
|
86
|
+
)
|
|
87
|
+
|
|
88
|
+
|
|
89
|
+
@dataclass(frozen=True)
|
|
90
|
+
class ECSServiceToAWSAccountRelProperties(CartographyRelProperties):
|
|
91
|
+
lastupdated: PropertyRef = PropertyRef("lastupdated", set_in_kwargs=True)
|
|
92
|
+
|
|
93
|
+
|
|
94
|
+
@dataclass(frozen=True)
|
|
95
|
+
class ECSServiceToAWSAccountRel(CartographyRelSchema):
|
|
96
|
+
target_node_label: str = "AWSAccount"
|
|
97
|
+
target_node_matcher: TargetNodeMatcher = make_target_node_matcher(
|
|
98
|
+
{"id": PropertyRef("AWS_ID", set_in_kwargs=True)}
|
|
99
|
+
)
|
|
100
|
+
direction: LinkDirection = LinkDirection.INWARD
|
|
101
|
+
rel_label: str = "RESOURCE"
|
|
102
|
+
properties: ECSServiceToAWSAccountRelProperties = (
|
|
103
|
+
ECSServiceToAWSAccountRelProperties()
|
|
104
|
+
)
|
|
105
|
+
|
|
106
|
+
|
|
107
|
+
@dataclass(frozen=True)
|
|
108
|
+
class ECSServiceSchema(CartographyNodeSchema):
|
|
109
|
+
label: str = "ECSService"
|
|
110
|
+
properties: ECSServiceNodeProperties = ECSServiceNodeProperties()
|
|
111
|
+
sub_resource_relationship: ECSServiceToAWSAccountRel = ECSServiceToAWSAccountRel()
|
|
112
|
+
other_relationships: OtherRelationships = OtherRelationships(
|
|
113
|
+
[
|
|
114
|
+
ECSServiceToECSClusterRel(),
|
|
115
|
+
ECSServiceToTaskDefinitionRel(),
|
|
116
|
+
]
|
|
117
|
+
)
|
|
@@ -0,0 +1,135 @@
|
|
|
1
|
+
from dataclasses import dataclass
|
|
2
|
+
|
|
3
|
+
from cartography.models.core.common import PropertyRef
|
|
4
|
+
from cartography.models.core.nodes import CartographyNodeProperties
|
|
5
|
+
from cartography.models.core.nodes import CartographyNodeSchema
|
|
6
|
+
from cartography.models.core.relationships import CartographyRelProperties
|
|
7
|
+
from cartography.models.core.relationships import CartographyRelSchema
|
|
8
|
+
from cartography.models.core.relationships import LinkDirection
|
|
9
|
+
from cartography.models.core.relationships import make_target_node_matcher
|
|
10
|
+
from cartography.models.core.relationships import OtherRelationships
|
|
11
|
+
from cartography.models.core.relationships import TargetNodeMatcher
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
@dataclass(frozen=True)
|
|
15
|
+
class ECSTaskDefinitionNodeProperties(CartographyNodeProperties):
|
|
16
|
+
id: PropertyRef = PropertyRef("taskDefinitionArn")
|
|
17
|
+
arn: PropertyRef = PropertyRef("taskDefinitionArn", extra_index=True)
|
|
18
|
+
family: PropertyRef = PropertyRef("family")
|
|
19
|
+
task_role_arn: PropertyRef = PropertyRef("taskRoleArn")
|
|
20
|
+
execution_role_arn: PropertyRef = PropertyRef("executionRoleArn")
|
|
21
|
+
network_mode: PropertyRef = PropertyRef("networkMode")
|
|
22
|
+
revision: PropertyRef = PropertyRef("revision")
|
|
23
|
+
status: PropertyRef = PropertyRef("status")
|
|
24
|
+
compatibilities: PropertyRef = PropertyRef("compatibilities")
|
|
25
|
+
runtime_platform_cpu_architecture: PropertyRef = PropertyRef(
|
|
26
|
+
"runtimePlatform.cpuArchitecture"
|
|
27
|
+
)
|
|
28
|
+
runtime_platform_operating_system_family: PropertyRef = PropertyRef(
|
|
29
|
+
"runtimePlatform.operatingSystemFamily"
|
|
30
|
+
)
|
|
31
|
+
requires_compatibilities: PropertyRef = PropertyRef("requiresCompatibilities")
|
|
32
|
+
cpu: PropertyRef = PropertyRef("cpu")
|
|
33
|
+
memory: PropertyRef = PropertyRef("memory")
|
|
34
|
+
pid_mode: PropertyRef = PropertyRef("pidMode")
|
|
35
|
+
ipc_mode: PropertyRef = PropertyRef("ipcMode")
|
|
36
|
+
proxy_configuration_type: PropertyRef = PropertyRef("proxyConfiguration.type")
|
|
37
|
+
proxy_configuration_container_name: PropertyRef = PropertyRef(
|
|
38
|
+
"proxyConfiguration.containerName"
|
|
39
|
+
)
|
|
40
|
+
registered_at: PropertyRef = PropertyRef("registeredAt")
|
|
41
|
+
deregistered_at: PropertyRef = PropertyRef("deregisteredAt")
|
|
42
|
+
registered_by: PropertyRef = PropertyRef("registeredBy")
|
|
43
|
+
ephemeral_storage_size_in_gib: PropertyRef = PropertyRef(
|
|
44
|
+
"ephemeralStorage.sizeInGiB"
|
|
45
|
+
)
|
|
46
|
+
region: PropertyRef = PropertyRef("Region", set_in_kwargs=True)
|
|
47
|
+
lastupdated: PropertyRef = PropertyRef("lastupdated", set_in_kwargs=True)
|
|
48
|
+
|
|
49
|
+
|
|
50
|
+
@dataclass(frozen=True)
|
|
51
|
+
class ECSTaskDefinitionToAWSAccountRelProperties(CartographyRelProperties):
|
|
52
|
+
lastupdated: PropertyRef = PropertyRef("lastupdated", set_in_kwargs=True)
|
|
53
|
+
|
|
54
|
+
|
|
55
|
+
@dataclass(frozen=True)
|
|
56
|
+
class ECSTaskDefinitionToAWSAccountRel(CartographyRelSchema):
|
|
57
|
+
target_node_label: str = "AWSAccount"
|
|
58
|
+
target_node_matcher: TargetNodeMatcher = make_target_node_matcher(
|
|
59
|
+
{"id": PropertyRef("AWS_ID", set_in_kwargs=True)}
|
|
60
|
+
)
|
|
61
|
+
direction: LinkDirection = LinkDirection.INWARD
|
|
62
|
+
rel_label: str = "RESOURCE"
|
|
63
|
+
properties: ECSTaskDefinitionToAWSAccountRelProperties = (
|
|
64
|
+
ECSTaskDefinitionToAWSAccountRelProperties()
|
|
65
|
+
)
|
|
66
|
+
|
|
67
|
+
|
|
68
|
+
@dataclass(frozen=True)
|
|
69
|
+
class ECSTaskDefinitionToECSTaskRelProperties(CartographyRelProperties):
|
|
70
|
+
lastupdated: PropertyRef = PropertyRef("lastupdated", set_in_kwargs=True)
|
|
71
|
+
|
|
72
|
+
|
|
73
|
+
@dataclass(frozen=True)
|
|
74
|
+
class ECSTaskDefinitionToECSTaskRel(CartographyRelSchema):
|
|
75
|
+
target_node_label: str = "ECSTask"
|
|
76
|
+
target_node_matcher: TargetNodeMatcher = make_target_node_matcher(
|
|
77
|
+
{"task_definition_arn": PropertyRef("taskDefinitionArn")}
|
|
78
|
+
)
|
|
79
|
+
direction: LinkDirection = LinkDirection.INWARD
|
|
80
|
+
rel_label: str = "HAS_TASK_DEFINITION"
|
|
81
|
+
properties: ECSTaskDefinitionToECSTaskRelProperties = (
|
|
82
|
+
ECSTaskDefinitionToECSTaskRelProperties()
|
|
83
|
+
)
|
|
84
|
+
|
|
85
|
+
|
|
86
|
+
@dataclass(frozen=True)
|
|
87
|
+
class ECSTaskDefinitionToTaskRoleRelProperties(CartographyRelProperties):
|
|
88
|
+
lastupdated: PropertyRef = PropertyRef("lastupdated", set_in_kwargs=True)
|
|
89
|
+
|
|
90
|
+
|
|
91
|
+
@dataclass(frozen=True)
|
|
92
|
+
class ECSTaskDefinitionToTaskRoleRel(CartographyRelSchema):
|
|
93
|
+
target_node_label: str = "AWSRole"
|
|
94
|
+
target_node_matcher: TargetNodeMatcher = make_target_node_matcher(
|
|
95
|
+
{"arn": PropertyRef("taskRoleArn")}
|
|
96
|
+
)
|
|
97
|
+
direction: LinkDirection = LinkDirection.OUTWARD
|
|
98
|
+
rel_label: str = "HAS_TASK_ROLE"
|
|
99
|
+
properties: ECSTaskDefinitionToTaskRoleRelProperties = (
|
|
100
|
+
ECSTaskDefinitionToTaskRoleRelProperties()
|
|
101
|
+
)
|
|
102
|
+
|
|
103
|
+
|
|
104
|
+
@dataclass(frozen=True)
|
|
105
|
+
class ECSTaskDefinitionToExecutionRoleRelProperties(CartographyRelProperties):
|
|
106
|
+
lastupdated: PropertyRef = PropertyRef("lastupdated", set_in_kwargs=True)
|
|
107
|
+
|
|
108
|
+
|
|
109
|
+
@dataclass(frozen=True)
|
|
110
|
+
class ECSTaskDefinitionToExecutionRoleRel(CartographyRelSchema):
|
|
111
|
+
target_node_label: str = "AWSRole"
|
|
112
|
+
target_node_matcher: TargetNodeMatcher = make_target_node_matcher(
|
|
113
|
+
{"arn": PropertyRef("executionRoleArn")}
|
|
114
|
+
)
|
|
115
|
+
direction: LinkDirection = LinkDirection.OUTWARD
|
|
116
|
+
rel_label: str = "HAS_EXECUTION_ROLE"
|
|
117
|
+
properties: ECSTaskDefinitionToExecutionRoleRelProperties = (
|
|
118
|
+
ECSTaskDefinitionToExecutionRoleRelProperties()
|
|
119
|
+
)
|
|
120
|
+
|
|
121
|
+
|
|
122
|
+
@dataclass(frozen=True)
|
|
123
|
+
class ECSTaskDefinitionSchema(CartographyNodeSchema):
|
|
124
|
+
label: str = "ECSTaskDefinition"
|
|
125
|
+
properties: ECSTaskDefinitionNodeProperties = ECSTaskDefinitionNodeProperties()
|
|
126
|
+
sub_resource_relationship: ECSTaskDefinitionToAWSAccountRel = (
|
|
127
|
+
ECSTaskDefinitionToAWSAccountRel()
|
|
128
|
+
)
|
|
129
|
+
other_relationships: OtherRelationships = OtherRelationships(
|
|
130
|
+
[
|
|
131
|
+
ECSTaskDefinitionToECSTaskRel(),
|
|
132
|
+
ECSTaskDefinitionToTaskRoleRel(),
|
|
133
|
+
ECSTaskDefinitionToExecutionRoleRel(),
|
|
134
|
+
]
|
|
135
|
+
)
|
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
from dataclasses import dataclass
|
|
2
|
+
|
|
3
|
+
from cartography.models.core.common import PropertyRef
|
|
4
|
+
from cartography.models.core.nodes import CartographyNodeProperties
|
|
5
|
+
from cartography.models.core.nodes import CartographyNodeSchema
|
|
6
|
+
from cartography.models.core.relationships import CartographyRelProperties
|
|
7
|
+
from cartography.models.core.relationships import CartographyRelSchema
|
|
8
|
+
from cartography.models.core.relationships import LinkDirection
|
|
9
|
+
from cartography.models.core.relationships import make_target_node_matcher
|
|
10
|
+
from cartography.models.core.relationships import OtherRelationships
|
|
11
|
+
from cartography.models.core.relationships import TargetNodeMatcher
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
@dataclass(frozen=True)
|
|
15
|
+
class ECSTaskNodeProperties(CartographyNodeProperties):
|
|
16
|
+
id: PropertyRef = PropertyRef("taskArn")
|
|
17
|
+
arn: PropertyRef = PropertyRef("taskArn", extra_index=True)
|
|
18
|
+
availability_zone: PropertyRef = PropertyRef("availabilityZone")
|
|
19
|
+
capacity_provider_name: PropertyRef = PropertyRef("capacityProviderName")
|
|
20
|
+
cluster_arn: PropertyRef = PropertyRef("clusterArn")
|
|
21
|
+
connectivity: PropertyRef = PropertyRef("connectivity")
|
|
22
|
+
connectivity_at: PropertyRef = PropertyRef("connectivityAt")
|
|
23
|
+
container_instance_arn: PropertyRef = PropertyRef("containerInstanceArn")
|
|
24
|
+
cpu: PropertyRef = PropertyRef("cpu")
|
|
25
|
+
created_at: PropertyRef = PropertyRef("createdAt")
|
|
26
|
+
desired_status: PropertyRef = PropertyRef("desiredStatus")
|
|
27
|
+
enable_execute_command: PropertyRef = PropertyRef("enableExecuteCommand")
|
|
28
|
+
execution_stopped_at: PropertyRef = PropertyRef("executionStoppedAt")
|
|
29
|
+
group: PropertyRef = PropertyRef("group")
|
|
30
|
+
health_status: PropertyRef = PropertyRef("healthStatus")
|
|
31
|
+
last_status: PropertyRef = PropertyRef("lastStatus")
|
|
32
|
+
launch_type: PropertyRef = PropertyRef("launchType")
|
|
33
|
+
memory: PropertyRef = PropertyRef("memory")
|
|
34
|
+
platform_version: PropertyRef = PropertyRef("platformVersion")
|
|
35
|
+
platform_family: PropertyRef = PropertyRef("platformFamily")
|
|
36
|
+
pull_started_at: PropertyRef = PropertyRef("pullStartedAt")
|
|
37
|
+
pull_stopped_at: PropertyRef = PropertyRef("pullStoppedAt")
|
|
38
|
+
started_at: PropertyRef = PropertyRef("startedAt")
|
|
39
|
+
started_by: PropertyRef = PropertyRef("startedBy")
|
|
40
|
+
stop_code: PropertyRef = PropertyRef("stopCode")
|
|
41
|
+
stopped_at: PropertyRef = PropertyRef("stoppedAt")
|
|
42
|
+
stopped_reason: PropertyRef = PropertyRef("stoppedReason")
|
|
43
|
+
stopping_at: PropertyRef = PropertyRef("stoppingAt")
|
|
44
|
+
task_definition_arn: PropertyRef = PropertyRef("taskDefinitionArn")
|
|
45
|
+
version: PropertyRef = PropertyRef("version")
|
|
46
|
+
ephemeral_storage_size_in_gib: PropertyRef = PropertyRef(
|
|
47
|
+
"ephemeralStorage.sizeInGiB"
|
|
48
|
+
)
|
|
49
|
+
region: PropertyRef = PropertyRef("Region", set_in_kwargs=True)
|
|
50
|
+
lastupdated: PropertyRef = PropertyRef("lastupdated", set_in_kwargs=True)
|
|
51
|
+
|
|
52
|
+
|
|
53
|
+
@dataclass(frozen=True)
|
|
54
|
+
class ECSTaskToECSClusterRelProperties(CartographyRelProperties):
|
|
55
|
+
lastupdated: PropertyRef = PropertyRef("lastupdated", set_in_kwargs=True)
|
|
56
|
+
|
|
57
|
+
|
|
58
|
+
@dataclass(frozen=True)
|
|
59
|
+
class ECSTaskToECSClusterRel(CartographyRelSchema):
|
|
60
|
+
target_node_label: str = "ECSCluster"
|
|
61
|
+
target_node_matcher: TargetNodeMatcher = make_target_node_matcher(
|
|
62
|
+
{"id": PropertyRef("ClusterArn", set_in_kwargs=True)}
|
|
63
|
+
)
|
|
64
|
+
direction: LinkDirection = LinkDirection.INWARD
|
|
65
|
+
rel_label: str = "HAS_TASK"
|
|
66
|
+
properties: ECSTaskToECSClusterRelProperties = ECSTaskToECSClusterRelProperties()
|
|
67
|
+
|
|
68
|
+
|
|
69
|
+
@dataclass(frozen=True)
|
|
70
|
+
class ECSTaskToContainerInstanceRelProperties(CartographyRelProperties):
|
|
71
|
+
lastupdated: PropertyRef = PropertyRef("lastupdated", set_in_kwargs=True)
|
|
72
|
+
|
|
73
|
+
|
|
74
|
+
@dataclass(frozen=True)
|
|
75
|
+
class ECSTaskToContainerInstanceRel(CartographyRelSchema):
|
|
76
|
+
target_node_label: str = "ECSContainerInstance"
|
|
77
|
+
target_node_matcher: TargetNodeMatcher = make_target_node_matcher(
|
|
78
|
+
{"id": PropertyRef("containerInstanceArn")}
|
|
79
|
+
)
|
|
80
|
+
direction: LinkDirection = LinkDirection.INWARD
|
|
81
|
+
rel_label: str = "HAS_TASK"
|
|
82
|
+
properties: ECSTaskToContainerInstanceRelProperties = (
|
|
83
|
+
ECSTaskToContainerInstanceRelProperties()
|
|
84
|
+
)
|
|
85
|
+
|
|
86
|
+
|
|
87
|
+
@dataclass(frozen=True)
|
|
88
|
+
class ECSTaskToAWSAccountRelProperties(CartographyRelProperties):
|
|
89
|
+
lastupdated: PropertyRef = PropertyRef("lastupdated", set_in_kwargs=True)
|
|
90
|
+
|
|
91
|
+
|
|
92
|
+
@dataclass(frozen=True)
|
|
93
|
+
class ECSTaskToAWSAccountRel(CartographyRelSchema):
|
|
94
|
+
target_node_label: str = "AWSAccount"
|
|
95
|
+
target_node_matcher: TargetNodeMatcher = make_target_node_matcher(
|
|
96
|
+
{"id": PropertyRef("AWS_ID", set_in_kwargs=True)}
|
|
97
|
+
)
|
|
98
|
+
direction: LinkDirection = LinkDirection.INWARD
|
|
99
|
+
rel_label: str = "RESOURCE"
|
|
100
|
+
properties: ECSTaskToAWSAccountRelProperties = ECSTaskToAWSAccountRelProperties()
|
|
101
|
+
|
|
102
|
+
|
|
103
|
+
@dataclass(frozen=True)
|
|
104
|
+
class ECSTaskSchema(CartographyNodeSchema):
|
|
105
|
+
label: str = "ECSTask"
|
|
106
|
+
properties: ECSTaskNodeProperties = ECSTaskNodeProperties()
|
|
107
|
+
sub_resource_relationship: ECSTaskToAWSAccountRel = ECSTaskToAWSAccountRel()
|
|
108
|
+
other_relationships: OtherRelationships = OtherRelationships(
|
|
109
|
+
[ECSTaskToContainerInstanceRel(), ECSTaskToECSClusterRel()]
|
|
110
|
+
)
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
from dataclasses import dataclass
|
|
2
|
+
|
|
3
|
+
from cartography.models.core.common import PropertyRef
|
|
4
|
+
from cartography.models.core.nodes import CartographyNodeProperties
|
|
5
|
+
from cartography.models.core.nodes import CartographyNodeSchema
|
|
6
|
+
from cartography.models.core.relationships import CartographyRelProperties
|
|
7
|
+
from cartography.models.core.relationships import CartographyRelSchema
|
|
8
|
+
from cartography.models.core.relationships import LinkDirection
|
|
9
|
+
from cartography.models.core.relationships import make_target_node_matcher
|
|
10
|
+
from cartography.models.core.relationships import OtherRelationships
|
|
11
|
+
from cartography.models.core.relationships import TargetNodeMatcher
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
@dataclass(frozen=True)
|
|
15
|
+
class EfsAccessPointNodeProperties(CartographyNodeProperties):
|
|
16
|
+
id: PropertyRef = PropertyRef("AccessPointArn")
|
|
17
|
+
arn: PropertyRef = PropertyRef("AccessPointArn", extra_index=True)
|
|
18
|
+
region: PropertyRef = PropertyRef("Region", set_in_kwargs=True)
|
|
19
|
+
access_point_id: PropertyRef = PropertyRef("AccessPointId")
|
|
20
|
+
file_system_id: PropertyRef = PropertyRef("FileSystemId")
|
|
21
|
+
lifecycle_state: PropertyRef = PropertyRef("LifeCycleState")
|
|
22
|
+
name: PropertyRef = PropertyRef("Name")
|
|
23
|
+
owner_id: PropertyRef = PropertyRef("OwnerId")
|
|
24
|
+
posix_gid: PropertyRef = PropertyRef("Gid")
|
|
25
|
+
posix_uid: PropertyRef = PropertyRef("Uid")
|
|
26
|
+
root_directory_path: PropertyRef = PropertyRef("RootDirectoryPath")
|
|
27
|
+
lastupdated: PropertyRef = PropertyRef("lastupdated", set_in_kwargs=True)
|
|
28
|
+
|
|
29
|
+
|
|
30
|
+
@dataclass(frozen=True)
|
|
31
|
+
class EfsAccessPointToAwsAccountRelProperties(CartographyRelProperties):
|
|
32
|
+
lastupdated: PropertyRef = PropertyRef("lastupdated", set_in_kwargs=True)
|
|
33
|
+
|
|
34
|
+
|
|
35
|
+
@dataclass(frozen=True)
|
|
36
|
+
class EfsAccessPointToAWSAccountRel(CartographyRelSchema):
|
|
37
|
+
target_node_label: str = "AWSAccount"
|
|
38
|
+
target_node_matcher: TargetNodeMatcher = make_target_node_matcher(
|
|
39
|
+
{"id": PropertyRef("AWS_ID", set_in_kwargs=True)},
|
|
40
|
+
)
|
|
41
|
+
direction: LinkDirection = LinkDirection.INWARD
|
|
42
|
+
rel_label: str = "RESOURCE"
|
|
43
|
+
properties: EfsAccessPointToAwsAccountRelProperties = (
|
|
44
|
+
EfsAccessPointToAwsAccountRelProperties()
|
|
45
|
+
)
|
|
46
|
+
|
|
47
|
+
|
|
48
|
+
@dataclass(frozen=True)
|
|
49
|
+
class EfsAccessPointToEfsFileSystemRelProperties(CartographyRelProperties):
|
|
50
|
+
lastupdated: PropertyRef = PropertyRef("lastupdated", set_in_kwargs=True)
|
|
51
|
+
|
|
52
|
+
|
|
53
|
+
@dataclass(frozen=True)
|
|
54
|
+
class EfsAccessPointToEfsFileSystemRel(CartographyRelSchema):
|
|
55
|
+
target_node_label: str = "EfsFileSystem"
|
|
56
|
+
target_node_matcher: TargetNodeMatcher = make_target_node_matcher(
|
|
57
|
+
{"id": PropertyRef("FileSystemId")},
|
|
58
|
+
)
|
|
59
|
+
direction: LinkDirection = LinkDirection.OUTWARD
|
|
60
|
+
rel_label: str = "ACCESS_POINT_OF"
|
|
61
|
+
properties: EfsAccessPointToEfsFileSystemRelProperties = (
|
|
62
|
+
EfsAccessPointToEfsFileSystemRelProperties()
|
|
63
|
+
)
|
|
64
|
+
|
|
65
|
+
|
|
66
|
+
@dataclass(frozen=True)
|
|
67
|
+
class EfsAccessPointSchema(CartographyNodeSchema):
|
|
68
|
+
label: str = "EfsAccessPoint"
|
|
69
|
+
properties: EfsAccessPointNodeProperties = EfsAccessPointNodeProperties()
|
|
70
|
+
sub_resource_relationship: EfsAccessPointToAWSAccountRel = (
|
|
71
|
+
EfsAccessPointToAWSAccountRel()
|
|
72
|
+
)
|
|
73
|
+
other_relationships: OtherRelationships = OtherRelationships(
|
|
74
|
+
[
|
|
75
|
+
EfsAccessPointToEfsFileSystemRel(),
|
|
76
|
+
]
|
|
77
|
+
)
|