diff --git a/CHANGELOG.md b/CHANGELOG.md index ea80e316..32968bcb 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,8 @@ ## UNRELEASED +BUG FIXES: +* config: Fixed a bug where the Nomad strategy and target plugins would fail to connect to Nomad's Task API socket [[GH-966](https://github.com/hashicorp/nomad-autoscaler/pull/966)] + ## 0.4.5 (August 13, 2024) IMPROVEMENTS: diff --git a/sdk/helper/nomad/config.go b/sdk/helper/nomad/config.go index 75578cc1..22041d16 100644 --- a/sdk/helper/nomad/config.go +++ b/sdk/helper/nomad/config.go @@ -112,7 +112,7 @@ func MergeMapWithAgentConfig(m map[string]string, cfg *api.Config) { } if cfg.Address != "" && m[configKeyNomadAddress] == "" { - m[configKeyNomadAddress] = cfg.Address + m[configKeyNomadAddress] = cfg.URL().String() } if cfg.Region != "" && m[configKeyNomadRegion] == "" { m[configKeyNomadRegion] = cfg.Region