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

"deploy" does not accept task -> template -> wait block #550

Open
jjdmol opened this issue Nov 19, 2024 · 0 comments
Open

"deploy" does not accept task -> template -> wait block #550

jjdmol opened this issue Nov 19, 2024 · 0 comments

Comments

@jjdmol
Copy link

jjdmol commented Nov 19, 2024

Description

The levant deploy command does not accept the wait parameter of the template block, see the example below, even though nomad does accept it.

NB: A work around for us is to use levant render, but nomad job run to deploy.

Levant job file:

job "test-job" {
  group "test-group" {
    count = 1

    task "test" {
      driver = "exec"

      config {
          command = "sleep"
          args = ["3600"]
      }

      template {
        wait {
          min     = "30s"
          max     = "300s"
        }
        data        = <<EOH
foo=bar
EOH

        destination = "local/env.txt"
        env         = true
      }
    }
  }
}

Running levant deploy test.levant.nomad yields:

[ERROR] levant/command: error parsing 'job': group: 'test-group', task: 'test', template -> 1 error(s) decoding:

* 'wait' expected a map, got 'slice'

Output of levant version:

Levant v0.3.3
@jjdmol jjdmol changed the title "deploy" does not accept template -> wait "deploy" does not accept task -> template -> wait block Nov 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant