diff --git a/nomad/setup-cluster.yml b/nomad/setup-cluster.yml index 4b9a6b4..53d3d4d 100644 --- a/nomad/setup-cluster.yml +++ b/nomad/setup-cluster.yml @@ -404,7 +404,18 @@ hosts: nomad_instances tasks: - # Need to wait until nomad is running + - name: Nomad API reachable? + uri: + url: "http://127.0.0.1:4646/v1/status/leader" + method: GET + status_code: 200 + register: nomad_check_result + retries: 6 + until: nomad_check_result is succeeded + delay: 10 + changed_when: false + run_once: true + - name: Bootstrap ACLs command: argv: