From 1315e92df567021d5cadb5aeb56d03868b88899d Mon Sep 17 00:00:00 2001 From: Chris Poupart Date: Tue, 18 Apr 2017 10:38:06 -0400 Subject: [PATCH 1/3] Add variables specific to RHEL 7 to allow use of mariadb instead of mysql. --- tasks/main.yml | 5 ++++- vars/RedHat-7.yml | 3 +++ 2 files changed, 7 insertions(+), 1 deletion(-) create mode 100644 vars/RedHat-7.yml diff --git a/tasks/main.yml b/tasks/main.yml index 83659fb..f21d7b2 100644 --- a/tasks/main.yml +++ b/tasks/main.yml @@ -1,7 +1,10 @@ --- - name: add the OS specific variables - include_vars: "{{ ansible_os_family }}.yml" + include_vars: "{{ item }}" + with_first_found: + - "{{ ansible_os_family }}-{{ ansible_distribution_major_version }}.yml" + - "{{ ansible_os_family }}.yml" tags: always - include: configure.yml diff --git a/vars/RedHat-7.yml b/vars/RedHat-7.yml new file mode 100644 index 0000000..0b784c1 --- /dev/null +++ b/vars/RedHat-7.yml @@ -0,0 +1,3 @@ +mysql_daemon: mariadb +mysql_hardening_mysql_conf_file: '/etc/my.cnf' +mysql_hardening_mysql_confd_dir: '/etc/my.cnf.d' From 311562fdfc0b6144428fd1f4c2ab423ffcc4e966 Mon Sep 17 00:00:00 2001 From: Chris Poupart Date: Tue, 18 Apr 2017 15:53:20 -0400 Subject: [PATCH 2/3] add test for centos 7.2 --- .kitchen.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.kitchen.yml b/.kitchen.yml index 4238a49..0b2054e 100644 --- a/.kitchen.yml +++ b/.kitchen.yml @@ -31,6 +31,10 @@ platforms: driver_config: box: opscode-centos-6.5 box_url: https://opscode-vm-bento.s3.amazonaws.com/vagrant/virtualbox/opscode_centos-6.5_chef-provisionerless.box +- name: centos-7.2 + driver_config: + box: opscode-centos-7.2 + box_url: http://opscode-vm-bento.s3.amazonaws.com/vagrant/virtualbox/opscode_centos-7.2_chef-provisionerless.box - name: oracle-6.4 driver_config: box: oracle-6.4 From 3fcae0e2848cada3439b49417fa95785762e8108 Mon Sep 17 00:00:00 2001 From: Chris Poupart Date: Fri, 21 Apr 2017 14:34:37 -0400 Subject: [PATCH 3/3] add ansible_distribution to standardize with other hardening roles. --- tasks/main.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tasks/main.yml b/tasks/main.yml index f21d7b2..ec5ad75 100644 --- a/tasks/main.yml +++ b/tasks/main.yml @@ -3,6 +3,8 @@ - name: add the OS specific variables include_vars: "{{ item }}" with_first_found: + - "{{ ansible_distribution }}-{{ ansible_distribution_major_version }}.yml" + - "{{ ansible_distribution }}.yml" - "{{ ansible_os_family }}-{{ ansible_distribution_major_version }}.yml" - "{{ ansible_os_family }}.yml" tags: always