Closed nofear87 closed 6 years ago
If I could help you with some further information please feel free to ask ;-)
It's weird, since 172.18.0.1 is the docker host itself...
There should be an error regarding a connection from 172.18.0.3, because syspass-app makes the connections to syspass-db container
yes you are right...its weird...in configuration I choose "syspass-db" as database host.
I have installed mysql client on syspass-app container with same result:
root@1c66e6ee5ff8:/var/www/html# mysql -u root -h syspass-db
ERROR 1130 (HY000): Host '172.18.0.1' is not allowed to connect to this MySQL server
Ping from syspass-db to syspass-app works fine, with correct ip resolution:
docker exec -it syspass-db ping syspass-app
PING syspass-app (172.18.0.3): 56 data bytes
64 bytes from 172.18.0.3: icmp_seq=0 ttl=64 time=0.135 ms
64 bytes from 172.18.0.3: icmp_seq=1 ttl=64 time=0.104 ms
64 bytes from 172.18.0.3: icmp_seq=2 ttl=64 time=0.102 ms
64 bytes from 172.18.0.3: icmp_seq=3 ttl=64 time=0.109 ms
I have installed mysql client on syspass-app container with same result:
Right, it's not allowed indeed. You need to issue docker exec -it syspass-db mysql
to get into mysql CLI
Ping from syspass-db to syspass-app works fine, with correct ip resolution:
The weird issue is the IP address thrown in the error message.
i understand the issue is related to that the container change ip address after resatart of the host can you send what commands need to be done to fix the ips so the syspass will continue after restart ?
I have the same problem like #5 using the default docker-compose.yml -> SQLSTATE[HY000] [1130] Host '172.18.0.1' is not allowed to connect to this MySQL server
I wonder why the syspass interface gets the 172.18.0.1 -> because container ip is ...0.2
Db ist pingable without any problems: