2022-09-29 13:13:09 +00:00
|
|
|
inputs:
|
|
|
|
recovery:
|
|
|
|
description: 'Recovery phrase'
|
|
|
|
passphrase:
|
|
|
|
description: 'Wallet password'
|
2022-12-05 16:51:53 +00:00
|
|
|
outputs:
|
|
|
|
token:
|
|
|
|
description: 'api-token of wallet'
|
|
|
|
value: ${{ steps.generate-api-token.outputs.api-token }}
|
2022-09-29 13:13:09 +00:00
|
|
|
runs:
|
|
|
|
using: 'composite'
|
|
|
|
steps:
|
|
|
|
- name: Create passphrase
|
|
|
|
shell: bash
|
|
|
|
run: echo "${{ inputs.passphrase }}" > ./passphrase
|
|
|
|
|
|
|
|
- name: Create recovery
|
|
|
|
shell: bash
|
|
|
|
run: echo "${{ inputs.recovery }}" > ./recovery
|
|
|
|
|
|
|
|
- name: Initialize wallet
|
|
|
|
shell: bash
|
2022-11-14 15:03:57 +00:00
|
|
|
run: vega wallet init -f --home ~/.vegacapsule/testnet/wallet
|
2022-09-29 13:13:09 +00:00
|
|
|
|
|
|
|
- name: Import wallet
|
|
|
|
shell: bash
|
2022-11-14 15:03:57 +00:00
|
|
|
run: vega wallet import -w UI_Trading_Test --recovery-phrase-file ./recovery -p ./passphrase --home ~/.vegacapsule/testnet/wallet
|
2022-09-29 13:13:09 +00:00
|
|
|
|
|
|
|
- name: Create public key 2
|
|
|
|
shell: bash
|
2022-11-14 15:03:57 +00:00
|
|
|
run: vega wallet key generate -w UI_Trading_Test -p ./passphrase --home ~/.vegacapsule/testnet/wallet
|
2022-09-29 13:13:09 +00:00
|
|
|
|
2022-11-08 13:01:37 +00:00
|
|
|
- name: Import network
|
2022-09-29 13:13:09 +00:00
|
|
|
shell: bash
|
2022-11-21 12:05:14 +00:00
|
|
|
run: vega wallet network import --from-url="https://raw.githubusercontent.com/vegaprotocol/networks-internal/main/stagnet3/vegawallet-stagnet3.toml" --force --home ~/.vegacapsule/testnet/wallet
|
2022-09-29 13:13:09 +00:00
|
|
|
|
2022-12-05 16:51:53 +00:00
|
|
|
- name: Init api-token
|
|
|
|
shell: bash
|
|
|
|
run: vega wallet api-token init --home ~/.vegacapsule/testnet/wallet --passphrase-file passphrase
|
|
|
|
|
|
|
|
- name: Generate api-token
|
|
|
|
id: generate-api-token
|
|
|
|
shell: bash
|
|
|
|
run: echo api-token=$(vega wallet api-token generate --wallet-name UI_Trading_Test --tokens-passphrase-file passphrase --wallet-passphrase-file passphrase --home ~/.vegacapsule/testnet/wallet | grep -Eo '[a-zA-Z0-9]{64}') >> $GITHUB_OUTPUT
|
|
|
|
|
2022-11-16 15:04:33 +00:00
|
|
|
- name: Start service using stagnet3 network
|
2022-09-29 13:13:09 +00:00
|
|
|
shell: bash
|
2022-12-05 16:51:53 +00:00
|
|
|
run: vega wallet service run -n stagnet3 --load-tokens --tokens-passphrase-file passphrase --no-version-check --automatic-consent --home ~/.vegacapsule/testnet/wallet &
|