Oct 25, 2023
0
Level 1
SQLSTATE[HY000] [1130] Host '192.168.32.6' is not allowed to connect to this MySQL server
Hey guys. I'm having problems with a laravel + docker project. I'm having this error and I don't know what happens. I've already modified the variables, I've started the project again but nothing helps and this error is still here. See my codes:
docker-compose.yml:
db mysql
mysql:
image: mysql:5.7.22
restart: unless-stopped
environment:
MYSQL_DATABASE: ${DB_DATABASE}
MYSQL_ROOT_PASSWORD: ${DB_PASSWORD}
MYSQL_PASSWORD: ${DB_PASSWORD}
MYSQL_USER: ${DB_USERNAME}
volumes:
- ./.docker/mysql/dbdata:/var/lib/mysql
env_file: .env
ports:
- 3306:3306
networks:
- laravel-eti
.env:
DB_CONNECTION=mysql DB_HOST=mysql DB_PORT=3306 DB_DATABASE=laravel_ead DB_USERNAME=root DB_PASSWORD=root
Another problem is that sometimes my mysql in the docker container keeps crashing when uploading it works but then it crashes
Please or to participate in this conversation.