标签:
yum -y install docker docker pull centos docker run -i -t centos /bin/bash yum -y install wget wget http://dev.mysql.com/get/mysql-community-release-el7-5.noarch.rpm rpm -ivh mysql-community-release-el7-5.noarch.rpm yum -y install mysql-community-server mysql-community-devel /usr/bin/mysql_install_db --user=mysql /usr/bin/mysqld_safe& /usr/bin/mysql -e "grant all privileges on *.* to ‘root‘@‘%‘ identified by ‘X7898700‘;" /usr/bin/mysql -e "grant all privileges on *.* to ‘root‘@‘localhost‘ identified by ‘X7898700‘;" /usr/bin/mysql -u root -pX7898700 -e "show databases;" exit docker ps -a docker commit 6a4e4f55b1e1 mysql56 docker run --name=mysqlserver3307 -t -i -d -p 3307:3306 mysql56 /usr/bin/mysqld_safe docker start mysqlserver3307 >> /home/logs/mysql3307.log
标签:
原文地址:http://www.cnblogs.com/fr5s/p/5642250.html