// run mysql:5.7
docker run --name mysql_max -p 3306:3306 \
-v ~/mysql57/:/etc/mysql/conf.d/ \
-e MYSQL_ROOT_PASSWORD=123 -d mysql:5.7.22
// get ip
docker inspect mysql_max
mysql -umaxwell -pmax
> show variables like '%log_bin%';
docker run -it -d --name maxwell zendesk/maxwell bin/maxwell --user=root \
--password=123 --host=mysql_max --producer=stdout
docker logs -ft maxwell
docker logs -ft mysql_max
docker exec -ti redis4maxwell
# redis-cli
> SUBSCRIBE maxwell
docker-compose up --build
docker exec -ti mysql_max bash -c "mysql < /mysql/test.sql"
albertchanx / docker-mysql-maxwell-kafka Goto Github PK
View Code? Open in Web Editor NEWmaxwell