This commit is contained in:
parent
9bb460d17b
commit
2777f28e81
5
ansible.cfg
Normal file
5
ansible.cfg
Normal file
@ -0,0 +1,5 @@
|
||||
[defaults]
|
||||
inventory=inventory.yml
|
||||
strategy_plugins = /opt/mitogen-0.2.9/ansible_mitogen/plugins
|
||||
strategy = mitogen_linear
|
||||
|
15
deploy.yml
Normal file
15
deploy.yml
Normal file
@ -0,0 +1,15 @@
|
||||
---
|
||||
###########################################################################
|
||||
# Deploy certs
|
||||
###########################################################################
|
||||
|
||||
- hosts: rprox
|
||||
roles:
|
||||
- { role: rprox, tags: rprox }
|
||||
|
||||
- hosts: docker
|
||||
roles:
|
||||
- { role: docker, tags: docker }
|
||||
|
||||
###########################################################################
|
||||
# end of file
|
11
group_vars/all.yml
Normal file
11
group_vars/all.yml
Normal file
@ -0,0 +1,11 @@
|
||||
---
|
||||
###########################################################################
|
||||
|
||||
# common connection vars
|
||||
ansible_user: sol
|
||||
ansible_become: yes
|
||||
ansible_python_interpreter: /usr/bin/python3
|
||||
|
||||
###########################################################################
|
||||
# end of file
|
||||
|
20
inventory.yml
Normal file
20
inventory.yml
Normal file
@ -0,0 +1,20 @@
|
||||
###########################################################################
|
||||
|
||||
all:
|
||||
children:
|
||||
|
||||
rprox:
|
||||
hosts:
|
||||
de-fra1.burble.com:
|
||||
ca-bhs2.burble.com:
|
||||
fr-rbx1.burble.com:
|
||||
|
||||
docker:
|
||||
hosts:
|
||||
uk-lon1.burble.com:
|
||||
fr-rbx1.burble.com:
|
||||
ca-bhs2.burble.com:
|
||||
de-fra1.burble.com:
|
||||
|
||||
###########################################################################
|
||||
# end of file
|
10
roles/docker/handlers/main.yml
Normal file
10
roles/docker/handlers/main.yml
Normal file
@ -0,0 +1,10 @@
|
||||
---
|
||||
########################################################################
|
||||
|
||||
- name: update traefik
|
||||
file:
|
||||
path: '{{ tpath }}/dynamic_conf/burble-dn42.yml'
|
||||
state: touch
|
||||
|
||||
########################################################################
|
||||
# end of file
|
22
roles/docker/tasks/main.yml
Normal file
22
roles/docker/tasks/main.yml
Normal file
@ -0,0 +1,22 @@
|
||||
---
|
||||
########################################################################
|
||||
|
||||
# upload the certs
|
||||
|
||||
- copy:
|
||||
src: 'certificates/{{ d }}/{{ f }}'
|
||||
dest: '{{ tpath }}/certs/{{ f }}'
|
||||
owner: root
|
||||
group: root
|
||||
mode: 0400
|
||||
vars:
|
||||
d: '{{ item.d }}'
|
||||
f: '{{ item.d }}.{{ item.s }}'
|
||||
loop:
|
||||
- { d: 'burble-dn42', s: 'crt' }
|
||||
- { d: 'burble-dn42', s: 'key' }
|
||||
notify: update traefik
|
||||
|
||||
########################################################################
|
||||
# end of file
|
||||
|
7
roles/docker/vars/main.yml
Normal file
7
roles/docker/vars/main.yml
Normal file
@ -0,0 +1,7 @@
|
||||
---
|
||||
########################################################################
|
||||
|
||||
tpath: '/export/apps/docker/config/traefik'
|
||||
|
||||
########################################################################
|
||||
# end of file
|
23
roles/rprox/tasks/main.yml
Normal file
23
roles/rprox/tasks/main.yml
Normal file
@ -0,0 +1,23 @@
|
||||
---
|
||||
########################################################################
|
||||
|
||||
# upload the certs
|
||||
|
||||
- copy:
|
||||
src: 'certificates/{{ d }}/{{ f }}'
|
||||
dest: '{{ npath }}/certs/{{ f }}'
|
||||
owner: '81001'
|
||||
group: '81001'
|
||||
mode: 0400
|
||||
vars:
|
||||
d: '{{ item.d }}'
|
||||
f: '{{ item.d }}.{{ item.s }}'
|
||||
loop:
|
||||
- { d: 'burble-dn42', s: 'crt' }
|
||||
- { d: 'burble-dn42', s: 'key' }
|
||||
- { d: 'collector-dn42', s: 'crt' }
|
||||
- { d: 'collector-dn42', s: 'key' }
|
||||
|
||||
########################################################################
|
||||
# end of file
|
||||
|
7
roles/rprox/vars/main.yml
Normal file
7
roles/rprox/vars/main.yml
Normal file
@ -0,0 +1,7 @@
|
||||
---
|
||||
########################################################################
|
||||
|
||||
npath: '/export/apps/nginx'
|
||||
|
||||
########################################################################
|
||||
# end of file
|
Loading…
x
Reference in New Issue
Block a user