You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am following the getting-started section on https://learn.hashicorp.com/tutorials/nomad/get-started-run?in=nomad/get-started.
However when running the job example.nomad I have the error:
2022-05-20T11:54:41+02:00: Task Group "cache" (failed to place 1 allocation):
* Constraint "${attr.consul.version} semver >= 1.7.0": 1 nodes excluded by filter
Having a successful deployment
Deployment "cd5820be" successful
Actual Result
The job is not deployed successfully due to the error
2022-05-20T11:54:41+02:00: Task Group "cache" (failed to place 1 allocation):
* Constraint "${attr.consul.version} semver >= 1.7.0": 1 nodes excluded by filter
Job file (if appropriate)
I think it is related to the service-part
service {
name = "redis-cache"
tags = ["global", "cache"]
port = "db"
# The "check" stanza instructs Nomad to create a Consul health check for
# this service. A sample check is provided here for your convenience;
# uncomment it to enable it. The "check" stanza is documented in the
# "service" stanza documentation.
# check {
# name = "alive"
# type = "tcp"
# interval = "10s"
# timeout = "2s"
# }
}
After removing it, the job is deployed successfully.
Nomad Server logs (if appropriate)
Nomad Client logs (if appropriate)
The text was updated successfully, but these errors were encountered:
As you identified, Nomad v.1.3.0 introduced implicit constraints for task groups which utilise Consul for service discovery. The getting started guide does not run Consul which causes this problem.
The fix has already been merged into main via #13044 which changes the example job to use Nomad for service discovery. This will be available in an upcoming Nomad point release. I'l therefore close this issue out.
Please reach out if you experience additional problems!
Thanks a lot for the fast response and quick update! I've seen that it has been fixed now with version 1.3.3 and that also redis has been updated to version 7.
I'm going to lock this issue because it has been closed for 120 days ⏳. This helps our maintainers find and focus on the active issues.
If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.
Nomad version
Nomad v1.3.0 (52e95d6)
Operating system and Environment details
NAME="CentOS Linux"
VERSION="7 (Core)"
ID="centos"
ID_LIKE="rhel fedora"
VERSION_ID="7"
PRETTY_NAME="CentOS Linux 7 (Core)"
Issue
I am following the getting-started section on https://learn.hashicorp.com/tutorials/nomad/get-started-run?in=nomad/get-started.
However when running the job example.nomad I have the error:
2022-05-20T11:54:41+02:00: Task Group "cache" (failed to place 1 allocation):
* Constraint "${attr.consul.version} semver >= 1.7.0": 1 nodes excluded by filter
Reproduction steps
Expected Result
Having a successful deployment
Deployment "cd5820be" successful
Actual Result
The job is not deployed successfully due to the error
2022-05-20T11:54:41+02:00: Task Group "cache" (failed to place 1 allocation):
* Constraint "${attr.consul.version} semver >= 1.7.0": 1 nodes excluded by filter
Job file (if appropriate)
I think it is related to the service-part
service {
name = "redis-cache"
tags = ["global", "cache"]
port = "db"
After removing it, the job is deployed successfully.
Nomad Server logs (if appropriate)
Nomad Client logs (if appropriate)
The text was updated successfully, but these errors were encountered: