1
0
Fork 0
mirror of https://github.com/iiab/iiab.git synced 2025-03-09 15:40:17 +00:00

cleaner Ansible messaging

This commit is contained in:
A Holt 2017-10-27 09:37:00 -04:00 committed by GitHub
parent e662025c4b
commit 504264a11f

View file

@ -68,17 +68,17 @@
# 'localhost' needs to be the last item for idempotency, see
# http://ansible.cc/docs/modules.html#mysql-user
# unfortunately it still doesn't work
- name: update mysql root password for localhost root accounts
- name: Update MySQL root password for localhost root accounts
mysql_user: name=root host={{ item }} password={{ mysql_root_password }} priv=*.*:ALL,GRANT
with_items:
- localhost
when: mysql_enabled
- name: copy .my.cnf file with root password credentials
- name: Copy .my.cnf file with root password credentials
template: src=my.cnf.j2 dest=/root/.my.cnf owner=root mode=0600
when: mysql_enabled
- name: update mysql root password for all remaining root accounts
- name: Update mysql root password for all remaining root accounts
mysql_user: name=root host={{ item }} password={{ mysql_root_password }} priv=*.*:ALL,GRANT
with_items:
# - "{{ iiab_hostname }}.{{ iiab_domain }}"
@ -86,15 +86,15 @@
- ::1
when: mysql_enabled
- name: delete anonymous MySQL server user for {{ ansible_hostname }}
- name: Delete anonymous MySQL server user for {{ ansible_hostname }}
mysql_user: user="" host="{{ ansible_hostname }}" state="absent"
when: mysql_enabled
- name: delete anonymous MySQL server user for localhost
- name: Delete anonymous MySQL server user for localhost
mysql_user: user="" state="absent"
when: mysql_enabled
- name: remove the MySQL test database
- name: Remove the MySQL test database
mysql_db: db=test state=absent
when: mysql_enabled
@ -106,7 +106,7 @@
when: not mysql_enabled
- name: add mysql to service list
- name: Add mysql to service list
ini_file: dest='{{ service_filelist }}'
section=mysql
option='{{ item.option }}'
@ -115,6 +115,6 @@
- option: name
value: mysql-database
- option: description
value: '"mySQL is a widely used database service on the Internet which runs on many platforms, and is often offered and available at hosting Internet Service Providers"'
value: '"MySQL is a widely used database service on the Internet which runs on many platforms, and is often offered and available at hosting Internet Service Providers"'
- option: enabled
value: "{{ mysql_enabled }}"