collection of ansible roles
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

30 lines
612 B

---
- name: install packages
package:
name: "{{ item }}"
loop: "{{ mysql_packages }}"
- name: reload facts
setup:
- name: enable and start systemd service
systemd:
name: "{{ item }}"
state: started
enabled: yes
loop: "{{ mysql_systemd_services }}"
- name: change mysql root password
mysql_user:
name: root
host: "{{ item }}"
password: "{{ mysql_root_password }}"
login_user: root
login_password: "{{ mysql_root_password }}"
check_implicit_admin: yes
priv: "*.*:ALL,GRANT"
loop:
- "{{ ansible_hostname }}"
- 127.0.0.1
- ::1
- localhost