kasperisager / php-dockerized

Dockerized PHP development stack: Nginx, MySQL, MongoDB, PHP-FPM, HHVM, Memcached, Redis, Elasticsearch and RabbitMQ

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Can't connect to mysql: Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock'

iamthom opened this issue · comments

commented

Hi, I'm trying your repo, and it is very great!

Well, got an issue with mysql. I could access this mysql -h localhost -P 3306 --protocol=tcp -uroot -p. But, my PHP app, cant connect to the database and throw error Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock'

How can I solve this?

commented

You rocks! Many thanks! It works now.

Beauty, no problem!