-
Notifications
You must be signed in to change notification settings - Fork 0
/
nomad.yml
38 lines (36 loc) · 875 Bytes
/
nomad.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
- name: create consul token for nomad
hosts: localhost
tasks:
- name: create nomad token
register: "consul_nomad_token"
consul_acl:
name: "nomad"
host: "{{ hostvars[groups['consul'][0]]['ansible_host']}}"
mgmt_token: "{{consul_acl_master_token}}"
rules:
- node: ""
policy: write
- service: ""
policy: write
- agent: ""
policy: write
- key: ""
policy: write
- session: ""
policy: write
- operator: read
- name: install nomad
hosts:
- nomad
- nomad_agent
tags: nomad
vars:
nomad_consul_token: "{{ hostvars['localhost']['consul_nomad_token'].token }}"
roles:
- brianshumate.nomad
- name: install docker
hosts:
- nomad_agent
tags: docker
roles:
- geerlingguy.docker