Skip to content
This repository has been archived by the owner on Jun 17, 2022. It is now read-only.

Commit

Permalink
use correct validator private key path
Browse files Browse the repository at this point in the history
  • Loading branch information
keppel committed May 4, 2019
1 parent aeede11 commit f5054aa
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions src/tendermint.ts
Original file line number Diff line number Diff line change
Expand Up @@ -92,17 +92,15 @@ export default async function createTendermintProcess({
}

/**
* overwrite the priv_validator.json file with the one specified.
* overwrite the priv_validator_key.json file with the one specified.
*
* the file is only copied if the pub_key in the specified file
* doesn't match the one in the tendermint home directory.
*
* information about our validator's last signature is kept in
* priv_validator.json as a safeguard against accidental double-signing.
*/

if (keyPath) {
let privValPath = join(home, 'config', 'priv_validator.json')
let privValPath = join(home, 'config', 'priv_validator_key.json')
if (!fs.existsSync(keyPath)) {
throw new Error(`no keys file found at ${keyPath}`)
}
Expand All @@ -127,7 +125,7 @@ export default async function createTendermintProcess({
})
await tendermintProcess.synced()
return {
close () {
close() {
closing = true
tendermintProcess.kill()
}
Expand Down

0 comments on commit f5054aa

Please sign in to comment.