Skip to content

Commit

Permalink
Added local api access to worker through credentials
Browse files Browse the repository at this point in the history
  • Loading branch information
MitchellAV committed Jul 26, 2024
1 parent c31d99b commit e868a82
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion workers/src/utility.py
Original file line number Diff line number Diff line change
Expand Up @@ -603,7 +603,11 @@ def get_login_secrets_from_aws() -> tuple[str, str]:

def with_credentials(logger: Logger | None = None):

username, password = get_login_secrets_from_aws()
if IS_LOCAL:
username = os.environ.get("admin_username", None)
password = os.environ.get("admin_password", None)
else:
username, password = get_login_secrets_from_aws()

if not username or not password:
raise Exception("Missing admin credentials")
Expand Down

0 comments on commit e868a82

Please sign in to comment.