Joined October 2012
·

Ryan Lazuka

Front End Developer at Falls Digital
·
Cleveland, OH
·
·
·

Posted to Secure mysql with ansible over 1 year ago

This does not seem to work when the destination for the .my.cnf file is in user's home dir

template: src=.my.cnf dest=/home/myuser/.my.cnf owner=myuser mode=0600

This returns the error:

msg: unable to connect to database, check login_user and login_password are correct or ~/.my.cnf has the credentials

However, I am able to ssh into my server and login into mysql as root ( via the /home/myuser/.my.cnf ) without any problems. It seems like ansible is failing to read the correct location of the .my.cnf file

Achievements
9 Karma
0 Total ProTip Views