hashicorp/nomad · error
One Consul Gateway Configuration must be set
Error message
One Consul Gateway Configuration must be set
What it means
ConsulGateway.Validate counts the ingress, terminating, and mesh config blocks; exactly one must be present per gateway. This error means zero (or more than one) of them was set, so the gateway type is ambiguous or absent.
Source
Thrown at nomad/structs/services.go:2007
}
if err := g.Mesh.Validate(); err != nil {
return err
}
// Exactly 1 of ingress/terminating/mesh must be set.
count := 0
if g.Ingress != nil {
count++
}
if g.Terminating != nil {
count++
}
if g.Mesh != nil {
count++
}
if count != 1 {
return fmt.Errorf("One Consul Gateway Configuration must be set")
}
return nil
}
// ConsulGatewayBindAddress is equivalent to Consul's api/catalog.go ServiceAddress
// struct, as this is used to encode values to pass along to Envoy (i.e. via
// JSON encoding).
type ConsulGatewayBindAddress struct {
Address string
Port int
}
func (a *ConsulGatewayBindAddress) Equal(o *ConsulGatewayBindAddress) bool {
if a == nil || o == nil {
return a == o
}
if a.Address != o.Address {View on GitHub (pinned to 482b49bf1a)
Solutions
- Add exactly one of ingress, terminating, or mesh inside the gateway block
- Remove extra gateway config blocks so only one remains
Defensive patterns
Strategy: validation
When it happens
Trigger: Thrown at nomad/structs/services.go:2007 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of hashicorp/nomad@482b49bf1a (2026-09-04).
Data as JSON: /api/errors/3134728304594d11.
Report an issue: GitHub.