Skip to content

LingJianCode/docker-study

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

start docker mysql

sudo docker run -e MYSQL_ROOT_PASSWORD="123456" --name mysql_test mysql:8.0

check all docker ip

sudo  docker inspect -f='{{.Name}} {{.NetworkSettings.IPAddress}} {{.HostConfig.PortBindings}}' $(sudo docker ps -aq)
sudo  docker inspect -f='{{.Name}} {{.NetworkSettings.docker_default.IPAddress}} {{.HostConfig.PortBindings}}' $(sudo docker ps -aq)

docker compose up (v2)

sudo docker compose -f mysql.yaml up -d

docker exec

sudo docker exec -it container_id /bin/bash

gtid replica

change replication source to source_host='172.18.0.3', source_port=3306,source_user='repl',source_password='repl',source_auto_position=1;

About

docker study and recod.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published