MYSQL

参考:

https://www.runoob.com/docker/docker-tutorial.html 

mysql

访问 MySQL 镜像库地址:https://hub.docker.com/_/mysql?tab=tags 

docker pull mysql 5.7  拉取mysql镜像

docker images |grep mysql 查看本地是否已有mysql下载

docker run -itd --name mysql -p 3306:3306 -e MYSQL_ROOT_PASSWORD=123456 容器ID

docker ps

g2d (进入第一个容器,进入mysql容器 )

连接mysql

IP地址 3306  root  123456

 

注:如启动docker后,但在docker ps 中找不到 执行:

docker rm name/CONTAINER ID   删除

mysql工具Sequel Pro

ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" < /dev/null 2> /dev/null ; brew install caskroom/cask/brew-cask 2> /dev/null

brew  install sequel-pro

 
 

安装redis3.2

docker pull redis:3.2

docker images |grep redis

 docker run -itd --name redis-test -p 6379:6379 redis容器

docker ps

redis-cli安装

brew tap ringohub/redis-cli

brew update && brew doctor

brew install redis-cli

redis工具Another Redis Desktop Manager

brew install --cask another-redis-desktop-manager

连接redis

ip地址   6379     redis-test 

 

 

安装MongoDB

docker pull mongo

docker images |grep mongo

docker run -itd --name mongo -p 27017:27017mongo容器 --auth

docker ps |grep mongo

docker exec -it mongo mongo admin

posted on 2020-11-30 15:40  jxba  阅读(105)  评论(0编辑  收藏  举报