add ansible support
This commit is contained in:
parent
1578f14c71
commit
d61af93d85
4 changed files with 51 additions and 0 deletions
15
ansible/ansible.cfg
Normal file
15
ansible/ansible.cfg
Normal file
|
|
@ -0,0 +1,15 @@
|
||||||
|
[defaults]
|
||||||
|
forks = 20
|
||||||
|
roles_path = roles/
|
||||||
|
library = library/
|
||||||
|
|
||||||
|
[inventory]
|
||||||
|
unparsed_is_failed=true
|
||||||
|
|
||||||
|
[ssh_connection]
|
||||||
|
pipelining = True
|
||||||
|
ssh_args = -o ControlMaster=auto -o ControlPersist=60s
|
||||||
|
timeout = 10
|
||||||
|
# shorten the ControlPath which is often too long; when it is,
|
||||||
|
# ssh connection reuse silently fails, making everything slower.
|
||||||
|
control_path = %(directory)s/%%C
|
||||||
17
ansible/inventory/runa.yml
Normal file
17
ansible/inventory/runa.yml
Normal file
|
|
@ -0,0 +1,17 @@
|
||||||
|
runa:
|
||||||
|
vars:
|
||||||
|
ansible_user: nschottelius
|
||||||
|
ssh_keys:
|
||||||
|
- "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIE9P5aA5O4Vsgg5sB6Ojk+z1f5F97hvwRRd3gi+a+GGq nico-2016"
|
||||||
|
|
||||||
|
children:
|
||||||
|
chdc1:
|
||||||
|
hosts:
|
||||||
|
mtx-elem-1.lat.internal.ru.com:
|
||||||
|
# 10.165.66.57
|
||||||
|
mtx-elem-2.lat.internal.ru.com:
|
||||||
|
# 10.165.66.58
|
||||||
|
mtx-syna-1.lat.internal.ru.com:
|
||||||
|
# 10.165.66.59
|
||||||
|
mtx-syna-2.lat.internal.ru.com:
|
||||||
|
# 10.165.66.60
|
||||||
12
ansible/playbook/runa.yml
Normal file
12
ansible/playbook/runa.yml
Normal file
|
|
@ -0,0 +1,12 @@
|
||||||
|
- name: Configure RUNA Matrix VMs
|
||||||
|
hosts: runa
|
||||||
|
tasks:
|
||||||
|
- name: Base
|
||||||
|
include_role:
|
||||||
|
name: base
|
||||||
|
tags:
|
||||||
|
- base
|
||||||
|
# - name: Add DNS to APU
|
||||||
|
# include_role:
|
||||||
|
# name: apu-service-dns
|
||||||
|
# when: apu_is_service_apu is defined
|
||||||
7
ansible/roles/base/tasks/main.yml
Normal file
7
ansible/roles/base/tasks/main.yml
Normal file
|
|
@ -0,0 +1,7 @@
|
||||||
|
---
|
||||||
|
- name: Add SSH public keys
|
||||||
|
authorized_key:
|
||||||
|
user: "nschottelius"
|
||||||
|
state: present
|
||||||
|
key: "{{ item }}"
|
||||||
|
with_items: "{{ ssh_keys }}"
|
||||||
Loading…
Add table
Add a link
Reference in a new issue