Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Validate connect block allowed only within group.service block #9450

Closed
shoenig opened this issue Nov 25, 2020 · 2 comments
Closed

Validate connect block allowed only within group.service block #9450

shoenig opened this issue Nov 25, 2020 · 2 comments
Labels
stage/accepted Confirmed, and intend to work on. No timeline committment though. theme/consul/connect Consul Connect integration type/bug
Milestone

Comments

@shoenig
Copy link
Member

shoenig commented Nov 25, 2020

This job file should not pass job submission validation

job "countdash" {
  datacenters = ["dc1"]

  group "api" {
    network {
      mode = "bridge"
      port "count" {}
    }



    task "web" {
      driver = "docker"

      config {
        image = "hashicorpnomad/counter-api:v1"
      }

      service {
	name = "count-api"
	port = "count"

	# should only be valid in group level
	connect {
	  sidecar_service {}
	}
      }      
    }
  }
}

But, it currently gets submitted:

$ nomad job run example.nomad
==> Monitoring evaluation "53764f96"
    Evaluation triggered by job "countdash"
    Allocation "c717939b" created: node "2ff1b94b", group "api"
==> Monitoring evaluation "53764f96"
    Evaluation within deployment: "054604a5"
    Allocation "c717939b" status changed: "pending" -> "running" (Tasks are running)
    Evaluation status changed: "pending" -> "complete"
==> Evaluation "53764f96" finished with status "complete"
@shoenig shoenig added theme/consul/connect Consul Connect integration type/bug stage/accepted Confirmed, and intend to work on. No timeline committment though. labels Nov 25, 2020
@tgross
Copy link
Member

tgross commented Jan 20, 2021

Closed by #9817. This will ship in Nomad 1.0.3

@github-actions
Copy link

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.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Oct 25, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
stage/accepted Confirmed, and intend to work on. No timeline committment though. theme/consul/connect Consul Connect integration type/bug
Projects
None yet
Development

No branches or pull requests

2 participants