I ran a mysql in docker
docker run --name mysql --network wp-net --network-alias mysql-host -e MYSQL_ROOT_PASSWORD=root mysql
Then ran a phpmyadmin in docker to connect to it
docker run --name myadmin --rm --link mysql:db \
--network wp-net \
--network-alias myadmin-host \
-p 8083:80 phpmyadmin/phpmyadmin
I go this error:
mysqli_real_connect(): The server requested authentication method unknown to the client [caching_sha2_password]
mysqli_real_connect(): (HY000/2054): The server requested authentication method unknown to the client
The working version:
A quick solution is using older version of mysql
docker run --name mysql --network wp-net --network-alias mysql-host -e MYSQL_ROOT_PASSWORD=root mysql:5.7.22
Problem solved.
You can also config mysql 8.0.11 to use old password
Feng
没有评论:
发表评论