ChrisWiegman/Primary-Vagrant — pull request #11 by mdkholy (2014-08-15 07:28:54+00:00)
Title: Fixed mysql_database issue

A fix for issue #4 which causes a mysql error when trying to use mysql::mysql_database provider.

```
Warning: Config file /etc/puppet/hiera.yaml not found, using Hiera defaults
Error: Could not prefetch mysql_database provider 'mysql': Execution of '/usr/bin/mysql -NBe show databases' returned 1: ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)

Error: Execution of '/usr/bin/mysql -NBe create database if not exists `wordpress.stable.pv` character set utf8 collate utf8_swedish_ci' returned 1: ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)

Error: /Stage[main]/Main/Mysql_database[wordpress.stable.pv]/ensure: change from absent to present failed: Execution of '/usr/bin/mysql -NBe create database if not exists `wordpress.stable.pv` character set utf8 collate utf8_swedish_ci' returned 1: ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)

Error: Execution of '/usr/bin/mysql -NBe create database if not exists `wordpress.trunk.pv` character set utf8 collate utf8_swedish_ci' returned 1: ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)

Error: /Stage[main]/Main/Mysql_database[wordpress.trunk.pv]/ensure: change from absent to present failed: Execution of '/usr/bin/mysql -NBe create database if not exists `wordpress.trunk.pv` character set utf8 collate utf8_swedish_ci' returned 1: ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)

Error: Execution of '/usr/bin/mysql -NBe create database if not exists `wordpress.core.pv` character set utf8 collate utf8_swedish_ci' returned 1: ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)

Error: /Stage[main]/Main/Mysql_database[wordpress.core.pv]/ensure: change from absent to present failed: Execution of '/usr/bin/mysql -NBe create database if not exists `wordpress.core.pv` character set utf8 collate utf8_swedish_ci' returned 1: ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)

Error: Could not start Service[mysqld]: Execution of '/sbin/start mysql' returned 1:
Error: /Stage[main]/Mysql::Server::Service/Service[mysqld]/ensure: change from stopped to running failed: Could not start Service[mysqld]: Execution of '/sbin/start mysql' returned 1:
Warning: /Stage[main]/Mysql::Server/Anchor[mysql::server::end]: Skipping because of failed dependencies
Warning: /Stage[main]/Mysql::Server::Account_security/Mysql_database[test]: Skipping because of failed dependencies
Error: Could not prefetch mysql_user provider 'mysql': Execution of '/usr/bin/mysql -NBe SELECT CONCAT(User, '@',Host) AS User FROM mysql.user' returned 1: ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)

Warning: /Stage[main]/Main/Mysql_user[username@localhost]: Skipping because of failed dependencies
Warning: /Stage[main]/Mysql::Server::Account_security/Mysql_user[@pv]: Skipping because of failed dependencies
Warning: /Stage[main]/Mysql::Server::Account_security/Mysql_user[@%]: Skipping because of failed dependencies
Warning: /Stage[main]/Mysql::Server::Account_security/Mysql_user[root@::1]: Skipping because of failed dependencies
Error: Could not prefetch mysql_grant provider 'mysql': Execution of '/usr/bin/mysql -NBe SELECT CONCAT(User, '@',Host) AS User FROM mysql.user' returned 1: ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)

Warning: /Stage[main]/Main/Mysql_grant[username@localhost/*.*]: Skipping because of failed dependencies
Warning: /Stage[main]/Mysql::Server::Account_security/Mysql_user[@localhost]: Skipping because of failed dependencies
Warning: /Stage[main]/Mysql::Server::Account_security/Mysql_user[root@pv]: Skipping because of failed dependencies
Warning: /Stage[main]/Mysql::Server::Account_security/Mysql_user[root@127.0.0.1]: Skipping because of failed dependencies
```