Skip to content

Commit

Permalink
refactor: change insert_keys function, from js script to curl command
Browse files Browse the repository at this point in the history
  • Loading branch information
abhiyana committed Feb 9, 2024
1 parent 4d53579 commit 0a7c25d
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions parachain/parachain.star
Original file line number Diff line number Diff line change
Expand Up @@ -252,9 +252,10 @@ def run_testnet_mainnet(plan, chain_type, relaychain_name, parachain):


def insert_keys(plan, service_name, private_phrase, sudo_key_in_hex, uri):
original_command = 'curl -vH \'Content-Type: application/json\' --data \'{{ "jsonrpc":"2.0", "method":"author_insertKey", "params":["aura", {0}, {1}],"id":1 }}\' {2}'
original_command = 'curl -vH \'Content-Type: application/json\' --data \'{{"jsonrpc":"2.0", "method":"author_insertKey", "params":["aura", "{0}", "{1}"], "id":1}}\' {2}'
modified_command = original_command.format(private_phrase, sudo_key_in_hex, uri)
plan.print(modified_command)
plan.run_sh(
run = modified_command,
image = "curlimages/curl:latest"
)
run=modified_command,
image="curlimages/curl:latest"
)

0 comments on commit 0a7c25d

Please sign in to comment.