xme / misp-docker

Docker container for MISP
96 stars 32 forks source link

misp-web cannot connect to misp-db container #20

Closed VictorCovalski closed 7 years ago

VictorCovalski commented 7 years ago

Hi, I've built the docker image following the instructions on the readme. The following error occurs when I try to run docker-compose up.

docker-compose up Recreating misp-db Recreating misp-web Attaching to misp-db, misp-web misp-web | Container started for the fist time. Setup might time a few minutes. Please wait... misp-web | (Details are logged in /tmp/install.log) misp-web | Configuring postfix misp-web | misp-web | Current default time zone: 'Etc/UTC' misp-web | Local time is now: Thu Jul 6 15:39:11 UTC 2017. misp-web | Universal Time is now: Thu Jul 6 15:39:11 UTC 2017. misp-web | misp-web | Creating MySQL database misp-web | MYSQL_ROOT_PASSWORD is set to 'SomeRandomPassword123!' misp-web | MYSQL_MISP_PASSWORD is set to 'SomeRandomPassword123!' misp-web | mysql: [Warning] Using a password on the command line interface can be insecure. misp-web | ERROR 1130 (HY000): Host '172.18.0.3' is not allowed to connect to this MySQL server misp-web exited with code 1

spacepatcher commented 7 years ago

@VictorCovalski Had the same problem. My solution to the problem: (in mysql console from database root user)

> USE mysql;
> UPDATE user SET host='%' WHERE host='localhost';
> FLUSH PRIVILEGES;

By default, MySQL root user is not allowed to login from external hosts.