Skip to content

Commit

Permalink
Enable access_edges via env variable (#2262)
Browse files Browse the repository at this point in the history
  • Loading branch information
meln1k authored Oct 21, 2024
1 parent d2acc74 commit fee7b5a
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion plugins/aws/fix_plugin_aws/collector.py
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down Expand Up @@ -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.")
Expand Down

0 comments on commit fee7b5a

Please sign in to comment.