diff --git a/plugins/aws/fix_plugin_aws/collector.py b/plugins/aws/fix_plugin_aws/collector.py index 03a08346c5..9911d0ea9e 100644 --- a/plugins/aws/fix_plugin_aws/collector.py +++ b/plugins/aws/fix_plugin_aws/collector.py @@ -2,6 +2,7 @@ from collections import defaultdict from concurrent.futures import Future, ThreadPoolExecutor from datetime import datetime, timedelta, timezone +import os from typing import List, Type, Optional, Union, cast, Any from fix_plugin_aws.access_edges import AccessEdgeCreator @@ -262,7 +263,7 @@ def get_last_run() -> Optional[datetime]: log.warning(f"Unexpected node type {node} in graph") raise Exception("Only AWS resources expected") - access_edge_collection_enabled = False + access_edge_collection_enabled = os.environ.get("ACCESS_EDGE_COLLECTION_ENABLED", "false").lower() == "true" if access_edge_collection_enabled and global_builder.config.collect_access_edges: # add access edges log.info(f"[Aws:{self.account.id}] Create access edges.")