Skip to content

Commit

Permalink
Updated the example nomad job spec to use task group name in the serv…
Browse files Browse the repository at this point in the history
…ice name
  • Loading branch information
diptanu committed Nov 27, 2015
1 parent e397b9b commit fe57034
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion command/init.go
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ job "example" {
}
service {
# name = redis
name = "${TASKGROUP}-redis"
tags = ["global", "cache"]
port = "db"
check {
Expand Down
1 change: 1 addition & 0 deletions nomad/job_endpoint.go
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ func (j *Job) Register(args *structs.JobRegisterRequest, reply *structs.JobRegis
return err
}

// Expand the service names
args.Job.ExpandAllServiceNames()

if args.Job.Type == structs.JobTypeCore {
Expand Down

0 comments on commit fe57034

Please sign in to comment.