fix(ipsec): Prepare IPsecUtil for upcoming changes
[csit.git] / fdio.infra.ansible / roles / nomad / templates / server.hcl.j2
1 server {
2     enabled = {{ nomad_node_server | bool | lower }}
3
4     {% if nomad_node_server | bool -%}
5         bootstrap_expect = {{ nomad_bootstrap_expect }}
6     {%- endif %}
7
8     {% if nomad_authoritative_region is defined %}
9         authoritative_region = "{{ nomad_authoritative_region }}"
10     {% endif %}
11
12 {% if nomad_use_consul == False %}
13     {% if nomad_retry_join | bool -%}
14         retry_join = [
15             {%- set comma = joiner(",") -%}
16             {% for server in nomad_servers -%}
17                 {{ comma() }}"{{ hostvars[server]['nomad_advertise_address'] | ipwrap }}"
18             {%- endfor -%} ]
19         retry_max = {{ nomad_retry_max }}
20         retry_interval = "{{ nomad_retry_interval }}"
21     {% else -%}
22         start_join = [
23             {%- set comma = joiner(",") -%}
24             {% for server in nomad_servers -%}
25                 {{ comma() }}"{{ hostvars[server]['nomad_advertise_address'] | ipwrap }}"
26             {%- endfor -%} ]
27     {%- endif %}
28 {% endif %}
29
30     encrypt = "{{ nomad_encrypt | default('') }}"
31
32     {% if nomad_node_gc_threshold -%}
33         node_gc_threshold = "{{ nomad_node_gc_threshold }}"
34     {%- endif %}
35
36     {% if nomad_job_gc_interval -%}
37         job_gc_interval = "{{ nomad_job_gc_interval }}"
38     {%- endif %}
39
40     {% if nomad_job_gc_threshold -%}
41         job_gc_threshold = "{{ nomad_job_gc_threshold }}"
42     {%- endif %}
43
44     {% if nomad_eval_gc_threshold -%}
45         eval_gc_threshold = "{{ nomad_eval_gc_threshold }}"
46     {%- endif %}
47
48     {% if nomad_deployment_gc_threshold -%}
49         deployment_gc_threshold = "{{ nomad_deployment_gc_threshold }}"
50     {%- endif %}
51
52 }