Skip to content

Commit

Permalink
fix activation
Browse files Browse the repository at this point in the history
  • Loading branch information
nicolasochem committed Feb 1, 2024
1 parent d833379 commit 9055054
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions utils/config-generator.py
Original file line number Diff line number Diff line change
Expand Up @@ -228,9 +228,10 @@ def expose_secret_key(account_name):
as is the case in Octez client's "secret_keys" file.
"""
if MY_POD_TYPE == "activating":
if "activation_account_authorized_key" in NETWORK_CONFIG:
return account_name == NETWORK_CONFIG["activation_account_authorized_key"]
return account_name == NETWORK_CONFIG["activation_account_name"]
return account_name in [
NETWORK_CONFIG.get("activation_account_authorized_key"),
NETWORK_CONFIG.get("activation_account_name"),
]

if MY_POD_TYPE == "signing":
return account_name in MY_POD_CONFIG.get("accounts")
Expand Down Expand Up @@ -308,9 +309,9 @@ def get_secret_key(account, key: Key):
elif signer_url:
# Use signer for this account even if there's a sk
sk = signer_url
print(f" Using remote signer url: {sk}")
print(f" Appending remote signer url as secret key: {sk}")
else:
print(" Loading secret key into pod")
print(" Appending secret key")

return sk

Expand Down Expand Up @@ -339,7 +340,6 @@ def import_keys(all_accounts):
sk = get_secret_key((account_name, account_values), key)
if not sk:
raise Exception("Secret key required but not provided.")
print(" Appending secret key")
secret_keys.append({"name": account_name, "value": sk})

pk_b58 = key.public_key()
Expand Down

0 comments on commit 9055054

Please sign in to comment.