<commit_before># vim:ts=2:sw=2:expandtab
---
- hosts: all
  tasks:
    - name: Read vars from secrets file
      include_vars: "{{ secrets_file }}"
      tags: always
      check_mode: "no"

# looks hackish, but this is apparently the "a clean, official way" to gather
# required facts from all hosts, regardless of the commandline --limit
# parameter
# We need this here, because in the group vars, we rely on the hostvars for
# the ip addresses of other hosts (e.g, mgnt1)
- hosts: all
  pre_tasks:
    - name: Gather facts from mgnt hosts (regardless of limit or tags)
      setup:
      delegate_to: "{{item}}"
      delegate_facts: "true"
      when: hostvars[item]['ansible_default_ipv4'] is not defined
      with_items: "{{groups['all']}}"
      tags: always

- hosts: all
  roles:
    - { role: basic,    tags: ['common'] }
    - { role: apt,      tags: ['common','apt']      }
    - role: firewall
      tags: ['common','firewall']
      when: docker.stdout_lines[0] != "docker"
    - role: ntp
      tags: ['common']
      when: docker.stdout_lines[0] != "docker"
    - { role: users,    tags: ['common','users'] }
    - { role: mail,     tags: ['common','mail'] }
#   - { role: logging,  tags: ['logging'  ] }

- hosts: mgnt1
  roles:
  #  - { role: ldap, tags: ['ldap'] }
  #  - { role: mta,  tags: ['mta' ] }

- hosts: mgnt2
  roles:
  #  - { role: logstash, tags: ['logstash'] }
  #  - { role: logstash, tags: ['logstash'] }

- hosts: lb
  roles:
    - { role: http_nginx,      tags: ['lb','http_nginx'] }
    - { role: tls_letsencrypt, tags: ['lb','tls_letsencrypt'] }
    - { role: https_haproxy,   tags: ['lb','https_haproxy'] }

- hosts: comanage
  roles:
    - { role: http_apache, tags: ['comanage', 'web'] }
    - { role: mysql, tags: ['comanage', 'db'] }
    - { role: comanage_mysql, tags: ['comanage', 'db'] }
    - { role: php56, tags: ['comanage', 'web'] }
    - { role: auth_mellon, tags: ['comanage', 'web'] }
    - { role: comanage, tags: ['comanage', 'web'] }

- hosts: ldap
  roles:
    - { role: ldap, tags: ['ldap'] }

- hosts: proxy
  roles:
    - { role: satosa,      tags: ['proxy','satosa'    ] }
    - { role: pyff,        tags: ['proxy','pyff'      ] }
    - { role: cmservice,   tags: ['proxy','cmservice' ] }
    - { role: mysql,       tags: ['proxy','mysql'     ] }
    - { role: proxy_mysql, tags: ['proxy','mysql'     ] }

- hosts: comanage
  roles:
    - { role: comanage_idp, tags: ['comanage', 'web'] }
    - { role: comanage_enable, tags: ['comanage', 'web'] }
    - { role: comanage_plugins, tags: ['comanage', 'web'] }

- hosts: client
  roles:
    - { role: http_dummy,  tags: ['client','test'] }

- hosts: meta
  roles:
    - { role: http_dummy,  tags: ['http']      }
    - { role: metadata,    tags: ['metadata']  }

- hosts: client
  roles:
    - { role: clients,     tags: ['clients']    }
<commit_msg>fix playbook for non-docker/vagrant builds (#18)<commit_after># vim:ts=2:sw=2:expandtab
---
- hosts: all
  tasks:
    - name: Read vars from secrets file
      include_vars: "{{ secrets_file }}"
      tags: always
      check_mode: "no"

# looks hackish, but this is apparently the "a clean, official way" to gather
# required facts from all hosts, regardless of the commandline --limit
# parameter
# We need this here, because in the group vars, we rely on the hostvars for
# the ip addresses of other hosts (e.g, mgnt1)
- hosts: all
  pre_tasks:
    - name: Gather facts from mgnt hosts (regardless of limit or tags)
      setup:
      delegate_to: "{{item}}"
      delegate_facts: "true"
      when: hostvars[item]['ansible_default_ipv4'] is not defined
      with_items: "{{groups['all']}}"
      tags: always

- hosts: all
  roles:
    - { role: basic,    tags: ['common'] }
    - { role: apt,      tags: ['common','apt']      }
    - role: firewall
      tags: ['common','firewall']
      when: docker is not defined or docker.stdout_lines[0] != "docker"
    - role: ntp
      tags: ['common']
      when: docker is not defined or docker.stdout_lines[0] != "docker"
    - { role: users,    tags: ['common','users'] }
    - { role: mail,     tags: ['common','mail'] }
#   - { role: logging,  tags: ['logging'  ] }

- hosts: mgnt1
  roles:
  #  - { role: ldap, tags: ['ldap'] }
  #  - { role: mta,  tags: ['mta' ] }

- hosts: mgnt2
  roles:
  #  - { role: logstash, tags: ['logstash'] }
  #  - { role: logstash, tags: ['logstash'] }

- hosts: lb
  roles:
    - { role: http_nginx,      tags: ['lb','http_nginx'] }
    - { role: tls_letsencrypt, tags: ['lb','tls_letsencrypt'] }
    - { role: https_haproxy,   tags: ['lb','https_haproxy'] }

- hosts: comanage
  roles:
    - { role: http_apache, tags: ['comanage', 'web'] }
    - { role: mysql, tags: ['comanage', 'db'] }
    - { role: comanage_mysql, tags: ['comanage', 'db'] }
    - { role: php56, tags: ['comanage', 'web'] }
    - { role: auth_mellon, tags: ['comanage', 'web'] }
    - { role: comanage, tags: ['comanage', 'web'] }

- hosts: ldap
  roles:
    - { role: ldap, tags: ['ldap'] }

- hosts: proxy
  roles:
    - { role: satosa,      tags: ['proxy','satosa'    ] }
    - { role: pyff,        tags: ['proxy','pyff'      ] }
    - { role: cmservice,   tags: ['proxy','cmservice' ] }
    - { role: mysql,       tags: ['proxy','mysql'     ] }
    - { role: proxy_mysql, tags: ['proxy','mysql'     ] }

- hosts: comanage
  roles:
    - { role: comanage_idp, tags: ['comanage', 'web'] }
    - { role: comanage_enable, tags: ['comanage', 'web'] }
    - { role: comanage_plugins, tags: ['comanage', 'web'] }

- hosts: client
  roles:
    - { role: http_dummy,  tags: ['client','test'] }

- hosts: meta
  roles:
    - { role: http_dummy,  tags: ['http']      }
    - { role: metadata,    tags: ['metadata']  }

- hosts: client
  roles:
    - { role: clients,     tags: ['clients']    }

{'fraction_non_alphanumeric': 0.1824918145786662, 'fraction_numerical': 0.003791142512493538, 'mean_word_length': 2.6139476961394768, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4375197', 'n_tokens_mistral': 2134, 'n_tokens_neox': 2137, 'n_words': 559}