From 60580742fcd9c925685c14748be3f9f6bdea18bc Mon Sep 17 00:00:00 2001 From: nazunalika Date: Sat, 9 Jan 2021 17:49:05 -0700 Subject: [PATCH] upcoming bz and account services --- .../playbooks/init-rocky-account-services.yml | 34 +++++++++++++++++++ ansible/playbooks/init-rocky-bugzilla.yml | 34 +++++++++++++++++++ ansible/playbooks/tasks/account_services.yml | 2 ++ ansible/playbooks/tasks/mantis.yml | 28 +++++++++++++++ ansible/playbooks/vars/ipa/fdns.yml | 3 +- ansible/playbooks/vars/ipa/rdns.yml | 15 +------- 6 files changed, 101 insertions(+), 15 deletions(-) create mode 100644 ansible/playbooks/init-rocky-account-services.yml create mode 100644 ansible/playbooks/init-rocky-bugzilla.yml create mode 100644 ansible/playbooks/tasks/account_services.yml create mode 100644 ansible/playbooks/tasks/mantis.yml diff --git a/ansible/playbooks/init-rocky-account-services.yml b/ansible/playbooks/init-rocky-account-services.yml new file mode 100644 index 0000000..a5da739 --- /dev/null +++ b/ansible/playbooks/init-rocky-account-services.yml @@ -0,0 +1,34 @@ +--- +# Preps a system to be part of Account Services +- name: Configure Account Services + hosts: "{{ host }}" + become: true + + handers: + - import_tasks: handlers/main.yml + + pre_tasks: + - name: Check if ansible cannot be run here + stat: + path: /etc/no-ansible + register: no_ansible + + - name: Verify if we can run ansible + assert: + that: + - "not no_ansible.stat.exists" + success_msg: "We are not able to run on this node" + fail_msg: "/etc/no-ansible exists - skipping run on this node" + + tasks: + - name: Deploy Account Services + import_tasks: tasks/account_services.yml + + post_tasks: + - name: Touching run file that ansible has ran here + file: + path: /var/log/ansible.run + state: touch + mode: '0644' + owner: root + group: root diff --git a/ansible/playbooks/init-rocky-bugzilla.yml b/ansible/playbooks/init-rocky-bugzilla.yml new file mode 100644 index 0000000..fe16092 --- /dev/null +++ b/ansible/playbooks/init-rocky-bugzilla.yml @@ -0,0 +1,34 @@ +--- +# Installs the mantis bug tracker +- name: Configure MantisBT + hosts: "{{ host }}" + become: true + + handers: + - import_tasks: handlers/main.yml + + pre_tasks: + - name: Check if ansible cannot be run here + stat: + path: /etc/no-ansible + register: no_ansible + + - name: Verify if we can run ansible + assert: + that: + - "not no_ansible.stat.exists" + success_msg: "We are not able to run on this node" + fail_msg: "/etc/no-ansible exists - skipping run on this node" + + tasks: + - name: Deploy Mantis + import_tasks: tasks/mantis.yml + + post_tasks: + - name: Touching run file that ansible has ran here + file: + path: /var/log/ansible.run + state: touch + mode: '0644' + owner: root + group: root diff --git a/ansible/playbooks/tasks/account_services.yml b/ansible/playbooks/tasks/account_services.yml new file mode 100644 index 0000000..f1ea699 --- /dev/null +++ b/ansible/playbooks/tasks/account_services.yml @@ -0,0 +1,2 @@ +--- +# Account Services diff --git a/ansible/playbooks/tasks/mantis.yml b/ansible/playbooks/tasks/mantis.yml new file mode 100644 index 0000000..b0133c9 --- /dev/null +++ b/ansible/playbooks/tasks/mantis.yml @@ -0,0 +1,28 @@ +--- +# Configure mantis +- name: Configure SELinux booleans + seboolean: + name: "{{ item }}" + persistent: true + state: true + with_items: + - httpd_can_network_connect_db + - httpd_can_network_connect + - httpd_can_sendmail + +- name: Install necessary packages + yum: + name: "{{ mantis_pkg }}" + state: present + vars: + mantis_pkg: + - php + - php-ldap + - httpd + - mod_ssl + - php-pgsql + - php-mbstring + - php-curl + - openldap + tags: + - packages diff --git a/ansible/playbooks/vars/ipa/fdns.yml b/ansible/playbooks/vars/ipa/fdns.yml index 88cb46c..c721d4e 100644 --- a/ansible/playbooks/vars/ipa/fdns.yml +++ b/ansible/playbooks/vars/ipa/fdns.yml @@ -1,3 +1,4 @@ --- fdns: - - boxbuild.rockylinux.org. + - rockylinux.org. + - aws.rockylinux.org. diff --git a/ansible/playbooks/vars/ipa/rdns.yml b/ansible/playbooks/vars/ipa/rdns.yml index 0676858..1149231 100644 --- a/ansible/playbooks/vars/ipa/rdns.yml +++ b/ansible/playbooks/vars/ipa/rdns.yml @@ -1,16 +1,3 @@ --- rdns: - - 0.1.10.in-addr.arpa. - - 2.1.10.in-addr.arpa. - - 4.1.10.in-addr.arpa. - - 6.1.10.in-addr.arpa. - - 8.1.10.in-addr.arpa. - - 10.1.10.in-addr.arpa. - - 14.1.10.in-addr.arpa. - - 0.16.10.in-addr.arpa. - - 2.16.10.in-addr.arpa. - - 4.16.10.in-addr.arpa. - - 6.16.10.in-addr.arpa. - - 8.16.10.in-addr.arpa. - - 10.16.10.in-addr.arpa. - - 14.16.10.in-addr.arpa. + - 32.10.in-addr.arpa.