Skip to content

Commit

Permalink
fix: use gentx --home-client flag
Browse files Browse the repository at this point in the history
  • Loading branch information
michaelfig committed Oct 7, 2020
1 parent 1b9ad64 commit 5595b41
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 4 deletions.
4 changes: 4 additions & 0 deletions packages/agoric-cli/lib/start.js
Original file line number Diff line number Diff line change
Expand Up @@ -282,9 +282,13 @@ export default async function startMain(progname, rawArgs, powers, opts) {
if (exitStatus) {
return exitStatus;
}
const keysHome = opts.sdk
? `_agstate/keys`
: `/usr/src/dapp/_agstate/keys`;
exitStatus = await chainSpawn([
'gentx',
'delegate0',
`--home-client=${keysHome}`,
'--keyring-backend=test',
`--chain-id=${CHAIN_ID}`,
`--amount=${DELEGATE0_COINS}`,
Expand Down
6 changes: 3 additions & 3 deletions packages/cosmic-swingset/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -79,11 +79,11 @@ scenario2-setup-nobuild:
done
# Create the bootstrap account.
mkdir t1/bootstrap
$(AGCH) --home=t1/n0 keys add bootstrap --keyring-backend=test
$(AGCH) --home=t1/n0 keys show -a bootstrap --keyring-backend=test > t1/bootstrap-address
$(AGCH) --home=t1/bootstrap keys add bootstrap --keyring-backend=test
$(AGCH) --home=t1/bootstrap keys show -a bootstrap --keyring-backend=test > t1/bootstrap-address
$(AGC) --home=t1/n0 add-genesis-account `cat t1/bootstrap-address` 100000000uagstake,100provisionpass,100sendpacketpass
# Create the (singleton) chain node.
$(AGC) --home=t1/n0 gentx --keyring-backend=test bootstrap --amount=1000000uagstake --chain-id=$(CHAIN_ID)
$(AGC) --home=t1/n0 gentx --keyring-backend=test --home-client=t1/bootstrap bootstrap --amount=1000000uagstake --chain-id=$(CHAIN_ID)
$(AGC) --home=t1/n0 collect-gentxs
$(AGC) --home=t1/n0 validate-genesis
../agoric-cli/bin/agoric set-defaults ag-chain-cosmos t1/n0/config
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,8 @@
become: yes
become_user: "{{ service }}"
shell: "\
{{ service }} gentx --keyring-backend=test --amount={{ STAKER_AMOUNT }} \
{{ service }} gentx --home-client=/home/{{ service }}/.ag-cosmos-helper \
--keyring-backend=test --amount={{ STAKER_AMOUNT }} \
{{ (website | default(None)) and '--website=' ~ website }} \
{{ (identity | default(None)) and '--identity=' ~ identity }} \
{{ STAKER }}-{{ STAKER_NODE }} --chain-id={{ CHAIN_NAME }} --output-document={{ json }}"
Expand Down

0 comments on commit 5595b41

Please sign in to comment.