Skip to content

Commit

Permalink
test
Browse files Browse the repository at this point in the history
  • Loading branch information
sbylica-splunk committed Feb 14, 2025
1 parent ae36729 commit 203fb53
Showing 1 changed file with 6 additions and 8 deletions.
14 changes: 6 additions & 8 deletions package/sbin/healthcheck.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,20 +16,18 @@ def str_to_bool(value):
}

def get_list_of_destinations():
destinations = []
found_destinations = []
regex = r"^SC4S_DEST_SPLUNK_HEC_(.*)_URL$"

print("Items")
for vn, _ in os.environ.items():
print(vn)
m = re.search(regex, vn)
r = m.group(1) if m else ""
if r != "":
destinations.append(r)
match = re.search(regex, vn)
if match:
found_destinations.append(match)

print("dest")
print(destinations)
return destinations
print(found_destinations)
return found_destinations

class Config:
SC4S_DEST_SPLUNK_HEC_DEFAULT_URL = os.getenv('SC4S_DEST_SPLUNK_HEC_DEFAULT_URL')
Expand Down

0 comments on commit 203fb53

Please sign in to comment.