I dockerize a MySQL db with this code : docker run --name db -e MYSQL_ROOT_PASSWORD=root -v $HOME/mysql-data:/var/lib/mysql -d mysql:5.7 which is supposed to create a password : root, BUT when I try to connect to database while entering that password, I get denied access. I can only access to DB if I log without entering any password (only if I leave the password blank).
What am I doing wrong or what did I misunderstand ?
PS: I tried to change the password to something else but root and got same result.