- name: make releng systems
  hosts: compose-x86-01.phx2.fedoraproject.org
  user: root
  gather_facts: False

  vars_files:
   - /srv/web/infra/ansible/vars/global.yml
   - "/srv/private/ansible/vars.yml"
   - /srv/web/infra/ansible/vars/{{ ansible_distribution }}.yml

  tasks:
  - include: "{{ tasks }}/virt_instance_create.yml"

  handlers:
  - include: "{{ handlers }}/restart_services.yml"

- name: Setup releng compose hosts
  hosts: releng-compose
  user: root
  gather_facts: True
  tags:
   - releng-compose

  vars_files:
   - /srv/web/infra/ansible/vars/global.yml
   - "/srv/private/ansible/vars.yml"
   - /srv/web/infra/ansible/vars/{{ ansible_distribution }}.yml

  roles:
  - base
  - hosts
  - fas_client
  - rkhunter
  - nagios_client
  - sudo
  - role: nfs/client
    mnt_dir: '/mnt/fedora_koji'
    nfs_src_dir: 'fedora_koji'
  - role: nfs/client
    mnt_dir: '/pub'
    nfs_src_dir: 'fedora_ftp/fedora.redhat.com/pub'
    when: not inventory_hostname.startswith('arm01')
  - releng

  tasks:
  # this is how you include other task lists
  - include: "{{ tasks }}/2fa_client.yml"
  - include: "{{ tasks }}/motd.yml"
  - include: "{{ tasks }}/common_scripts.yml"

  handlers:
  - include: "{{ handlers }}/restart_services.yml"
