initial ansible config for openqa, openqa-stg, openqa workers
This commit is contained in:
parent
5bd2413fa3
commit
6bce843a11
10 changed files with 201 additions and 5 deletions
52
playbooks/groups/openqa-workers.yml
Normal file
52
playbooks/groups/openqa-workers.yml
Normal file
|
@ -0,0 +1,52 @@
|
|||
# create a new openqa worker server system
|
||||
# NOTE: should be used with --limit most of the time
|
||||
# NOTE: most of these vars_path come from group_vars/backup_server or from hostvars
|
||||
# This has an extra role that configures the virthost to be used with beaker for
|
||||
# virtual machine clients
|
||||
|
||||
- name: basic configuration
|
||||
hosts: openqa-workers,openqa-stg-workers
|
||||
user: root
|
||||
gather_facts: True
|
||||
|
||||
vars_files:
|
||||
- /srv/web/infra/ansible/vars/global.yml
|
||||
- "/srv/private/ansible/vars.yml"
|
||||
- /srv/web/infra/ansible/vars/{{ ansible_distribution }}.yml
|
||||
|
||||
roles:
|
||||
- base
|
||||
- rkhunter
|
||||
- { role: denyhosts, when: ansible_distribution_major_version|int != 7 }
|
||||
- nagios_client
|
||||
- hosts
|
||||
- fas_client
|
||||
- collectd/base
|
||||
- { role: iscsi_client, when: datacenter == "phx2" }
|
||||
- sudo
|
||||
- { role: openvpn/client, when: datacenter != "phx2" }
|
||||
- { role: beaker/virthost, tags: ['beakervirthost'] }
|
||||
|
||||
tasks:
|
||||
- include: "{{ tasks }}/yumrepos.yml"
|
||||
- include: "{{ tasks }}/2fa_client.yml"
|
||||
- include: "{{ tasks }}/motd.yml"
|
||||
|
||||
handlers:
|
||||
- include: "{{ handlers }}/restart_services.yml"
|
||||
|
||||
#- name: configure openqa workers
|
||||
# hosts: openqa-workers, openqa-stg-workers
|
||||
# user: root
|
||||
# gather_facts: True
|
||||
#
|
||||
# vars_files:
|
||||
# - /srv/web/infra/ansible/vars/global.yml
|
||||
# - "/srv/private/ansible/vars.yml"
|
||||
# - /srv/web/infra/ansible/vars/{{ ansible_distribution }}.yml
|
||||
#
|
||||
# roles:
|
||||
# - { role: openqa/something, tags: ['something'] }
|
||||
#
|
||||
# handlers:
|
||||
# - include: "{{ handlers }}/restart_services.yml"
|
52
playbooks/groups/openqa.yml
Normal file
52
playbooks/groups/openqa.yml
Normal file
|
@ -0,0 +1,52 @@
|
|||
---
|
||||
# create a new taskotron staging server
|
||||
# NOTE: make sure there is room/space for this server on the vmhost
|
||||
# NOTE: most of these vars_path come from group_vars/mirrorlist or from hostvars
|
||||
|
||||
- include: "/srv/web/infra/ansible/playbooks/include/virt-create.yml myhosts=openqa,openqa-stg"
|
||||
|
||||
- name: make the box be real
|
||||
hosts: openqa, openqa-stg
|
||||
user: root
|
||||
gather_facts: True
|
||||
|
||||
vars_files:
|
||||
- /srv/web/infra/ansible/vars/global.yml
|
||||
- "/srv/private/ansible/vars.yml"
|
||||
- /srv/web/infra/ansible/vars/{{ ansible_distribution }}.yml
|
||||
|
||||
roles:
|
||||
- { role: base, tags: ['base'] }
|
||||
- { role: rkhunter, tags: ['rkhunter'] }
|
||||
- { role: nagios_client, tags: ['nagios_client'] }
|
||||
- { role: hosts, tags: ['hosts']}
|
||||
- { role: fas_client, tags: ['fas_client'] }
|
||||
- { role: collectd/base, tags: ['collectd_base'] }
|
||||
- { role: yum-cron, tags: ['yumcron'] }
|
||||
- { role: sudo, tags: ['sudo'] }
|
||||
- apache
|
||||
|
||||
tasks:
|
||||
# this is how you include other task lists
|
||||
- include: "{{ tasks }}/yumrepos.yml"
|
||||
- include: "{{ tasks }}/2fa_client.yml"
|
||||
- include: "{{ tasks }}/motd.yml"
|
||||
|
||||
handlers:
|
||||
- include: "{{ handlers }}/restart_services.yml"
|
||||
|
||||
#- name: configure openqa
|
||||
# hosts: openqa, openqa-stg
|
||||
# user: root
|
||||
# gather_facts: True
|
||||
#
|
||||
# vars_files:
|
||||
# - /srv/web/infra/ansible/vars/global.yml
|
||||
# - "/srv/private/ansible/vars.yml"
|
||||
# - /srv/web/infra/ansible/vars/{{ ansible_distribution }}.yml
|
||||
#
|
||||
# roles:
|
||||
# - { role: openqa/something, tags: ['something'] }
|
||||
#
|
||||
# handlers:
|
||||
# - include: "{{ handlers }}/restart_services.yml"
|
Loading…
Add table
Add a link
Reference in a new issue