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

0.5-rc - interpolation inconsistencies #1958

Closed
jippi opened this issue Nov 8, 2016 · 1 comment
Closed

0.5-rc - interpolation inconsistencies #1958

jippi opened this issue Nov 8, 2016 · 1 comment

Comments

@jippi
Copy link
Contributor

jippi commented Nov 8, 2016

Hi,

I've just hit a care where interpolation works for check = script while check = tcp does not interpolate.

      # this service is used to give all sentinel servers
      # a common connection point when bootstrapping the cluster.
      #
      # we only really use NOMAD_ALLOC_INDEX = 0
      service {
        name = "redis-discovery"
        port = "redis"
        tags = ["index-${NOMAD_ALLOC_INDEX}"]

        check {
          type     = "tcp"
          name     = "redis-discovery tcp check #${NOMAD_ALLOC_INDEX}"
          port     = "redis"
          interval = "10s"
          timeout  = "2s"
        }
      }

      # this service will register any redis instance that
      # have more than env(REQUIRED_NUMBER_OF_SLAVES || 0) slaves
      #
      service {
        name = "redis"
        port = "redis"
        tags = ["master"]

        check {
          type     = "script"
          name     = "redis script check #${NOMAD_ALLOC_INDEX}"
          interval = "10s"
          timeout  = "5s"
          command  = "/usr/local/bin/check-redis-master"
        }
      }

image

image

@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 Dec 18, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant