mirror of
https://github.com/kemko/nomad.git
synced 2026-01-06 10:25:42 +03:00
address comments
This commit is contained in:
@@ -412,7 +412,7 @@ func (a *Agent) setupClient() error {
|
||||
}
|
||||
a.client = client
|
||||
|
||||
// Create the Nomad Server services for Consul
|
||||
// Create the Nomad Client services for Consul
|
||||
if a.config.Consul.AutoRegister && a.config.Consul.ClientServiceName != "" {
|
||||
httpServ := &structs.Service{
|
||||
Name: a.config.Consul.ClientServiceName,
|
||||
|
||||
@@ -54,7 +54,7 @@ const (
|
||||
|
||||
// nomadServicePrefix is the first prefix that scopes all Nomad registered
|
||||
// services
|
||||
nomadServicePrefix = "nomad-registered-service"
|
||||
nomadServicePrefix = "_nomad"
|
||||
|
||||
// The periodic time interval for syncing services and checks with Consul
|
||||
syncInterval = 5 * time.Second
|
||||
@@ -953,8 +953,8 @@ func (c *Syncer) runCheck(check Check) {
|
||||
}
|
||||
}
|
||||
|
||||
// KeepDomains prunes all services that do not exist in the passed domains
|
||||
func (c *Syncer) KeepDomains(domains []ServiceDomain) error {
|
||||
// ReapUnmatched prunes all services that do not exist in the passed domains
|
||||
func (c *Syncer) ReapUnmatched(domains []ServiceDomain) error {
|
||||
servicesInConsul, err := c.ConsulClient().Agent().Services()
|
||||
if err != nil {
|
||||
return err
|
||||
|
||||
Reference in New Issue
Block a user