fix: add some logs on the update (#10036)

* add some logs on the update

* changelog update
This commit is contained in:
Jonathan Gimeno 2021-09-02 17:38:07 +02:00 committed by GitHub
parent 5cf2dae4b5
commit ddabfd36c6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 4 additions and 0 deletions

View File

@ -44,6 +44,7 @@ Ref: https://keepachangelog.com/en/1.0.0/
### Improvements
+ [\#10018](https://github.com/cosmos/cosmos-sdk/pull/10018) Strict boolean argument parsing: cosmovisor will fail if user will not set correctly a boolean variable. Correct values are: "true", "false", "" (not setting) - all case not sensitive.
+ [\#10036](https://github.com/cosmos/cosmos-sdk/pull/10036) Improve logs when downloading the binary.
## v0.1 2021-08-06

View File

@ -84,6 +84,7 @@ func (l Launcher) WaitForUpgradeOrExit(cmd *exec.Cmd) (bool, error) {
select {
case <-l.fw.MonitorUpdate(currentUpgrade):
// upgrade - kill the process and restart
fmt.Println("[cosmovisor] Daemon shutting down in an attempt to restart")
_ = cmd.Process.Kill()
case err := <-cmdDone:
l.fw.Stop()

View File

@ -36,9 +36,11 @@ func DoUpgrade(cfg *Config, info UpgradeInfo) error {
}
// If not there, then we try to download it... maybe
fmt.Println("[cosmovisor] No upgrade binary found, beginning to download it")
if err := DownloadBinary(cfg, info); err != nil {
return fmt.Errorf("cannot download binary. %w", err)
}
fmt.Println("[cosmovisor] Downloading binary complete")
// and then set the binary again
if err := EnsureBinary(cfg.UpgradeBin(info.Name)); err != nil {