Joined December 2013
·
Achievements
47 Karma
1,049 Total ProTip Views
Walrus
The walrus is no stranger to variety. Use at least 4 different languages throughout all your repos
Mongoose
Have at least one original repo where Ruby is the dominant language
Forked
Have a project valued enough to be forked by someone else
Charity
Fork and commit to someone's open source project in need
I like that you're using Ansible. It puts you on track for making the installation and configuration of mysql a simple, repeatable process. You're off to a good start!
I think there might be a better way to do this though. Firstly, ansible includes several mysql modules, one of which is mysqluser. The mysqluser module will let you modify users, create users, change passwords, etc. This would be preferred over a shell task. Check it out in the documentation here: http://docs.ansible.com/mysql_user_module.html
Secondly, there is a really good role on the Galaxy community site that gives you everything needed for installing, configuring and hardening a mysql host. It's available here: https://galaxy.ansibleworks.com/list#/roles/1