Skip to content

Commit

Permalink
Merge pull request #5 from cloudfoundry-community/camelcase
Browse files Browse the repository at this point in the history
correct env var name
  • Loading branch information
itsouvalas authored Aug 1, 2024
2 parents ecc823c + 644a8d4 commit 7ec07b0
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions cmd/scheduler/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -104,17 +104,17 @@ func main() {

log.Info(tag, "trying to acquire the desired number of workers")

workerNumStr := os.Getenv("workerNum")
workerNumStr := os.Getenv("WORKER_NUM")
if len(workerNumStr) == 0 {
workerNumStr = "20"
log.Info(tag, "No `workerNum` provided, defaulting to 20")
log.Info(tag, "No `WORKER_NUM` provided, defaulting to 20")
} else {
log.Info(tag, fmt.Sprintf("workerNum set to %s", workerNumStr))
log.Info(tag, fmt.Sprintf("WORKER_NUM set to %s", workerNumStr))
}

workerNum, err := strconv.Atoi(workerNumStr)
if err != nil {
log.Error("Invalid workerNum: %v", err.Error())
log.Error("Invalid WORKER_NUM: %v", err.Error())
os.Exit(255)
}

Expand Down

0 comments on commit 7ec07b0

Please sign in to comment.