Skip to content

Commit

Permalink
fix(deploy): status-progress-period and hooks-status-progress-period …
Browse files Browse the repository at this point in the history
…params fix

Added WERF_STATUS_PROGRESS_PERIOD and WERF_HOOKS_STATUS_PROGRESS_PERIOD environment variables in addition to WERF_STATUS_PROGRESS_PERIOD_SECONDS and WERF_HOOKS_STATUS_PROGRESS_PERIOD_SECONDS.
  • Loading branch information
distorhead committed Dec 7, 2021
1 parent 2f2d271 commit 2522b25
Showing 1 changed file with 20 additions and 2 deletions.
22 changes: 20 additions & 2 deletions cmd/werf/common/common.go
Expand Up @@ -498,7 +498,16 @@ func statusProgressPeriodDefaultValue() *int64 {
}

if v == nil {
return &defaultValue
v, err = GetIntEnvVar("WERF_STATUS_PROGRESS_PERIOD")
if err != nil {
TerminateWithError(err.Error(), 1)
}

if v == nil {
return &defaultValue
} else {
return v
}
} else {
return v
}
Expand Down Expand Up @@ -528,7 +537,16 @@ func hooksStatusProgressPeriodDefaultValue() *int64 {
}

if v == nil {
return defaultValue
v, err = GetIntEnvVar("WERF_HOOKS_STATUS_PROGRESS_PERIOD")
if err != nil {
TerminateWithError(err.Error(), 1)
}

if v == nil {
return defaultValue
} else {
return v
}
} else {
return v
}
Expand Down

0 comments on commit 2522b25

Please sign in to comment.