当前位置:网站首页>docker 方法安装mysql
docker 方法安装mysql
2022-07-06 17:30:00 【love_521_】
docker安装mysql全过程,自从使用了docker,越来越喜欢这个神器,安装方法简单明了,安装方法如下:
拉取镜像
docker pull mysql:5.7 --platform linux/x86_64
查看镜像
docker images
创建相关的文件夹
mkdir -p ~/mydocker/mysql/conf
mkdir -p ~/mydocker/mysql/logs
mkdir -p ~/mydocker/mysql/data
chmod -R 777 ~/mydocker/mysql/
运行容器
docker run -p 3306:3306 --name mysql -v ~/mydocker/mysql/conf:/etc/mysql/conf.d -v ~/mydocker/mysql/logs:/var/log/mysql -v ~/mydocker/mysql/data:/var/lib/mysql -e MYSQL_ROOT_PASSWORD=123456 -d mysql:5.7 --character-set-server=utf8mb4 --collation-server=utf8mb4_unicode_ci
查看容器
docker ps
边栏推荐
- 腾讯云 WebShell 体验
- Zabbix 5.0:通过LLD方式自动化监控阿里云RDS
- 做微服务研发工程师的一年来的总结
- Boot - Prometheus push gateway use
- pyflink的安装和测试
- Install Firefox browser on raspberry pie /arm device
- Supersocket 1.6 creates a simple socket server with message length in the header
- Trace tool for MySQL further implementation plan
- ARM裸板调试之JTAG调试体验
- [batch dos-cmd command - summary and summary] - string search, search, and filter commands (find, findstr), and the difference and discrimination between find and findstr
猜你喜欢

【案例分享】网络环路检测基本功能配置

Configuring the stub area of OSPF for Huawei devices

【批處理DOS-CMD命令-匯總和小結】-字符串搜索、查找、篩選命令(find、findstr),Find和findstr的區別和辨析

第四篇,STM32中断控制编程

Building a dream in the digital era, the Xi'an station of the city chain science and Technology Strategy Summit ended smoothly

身体质量指数程序,入门写死的小程序项目

动态规划思想《从入门到放弃》

Chenglian premium products has completed the first step to enter the international capital market by taking shares in halber international
![[牛客] B-完全平方数](/img/bd/0812b4fb1c4f6217ad5a0f3f3b8d5e.png)
[牛客] B-完全平方数

Part VI, STM32 pulse width modulation (PWM) programming
随机推荐
What are the differences between Oracle Linux and CentOS?
View remote test data and records anytime, anywhere -- ipehub2 and ipemotion app
Install Firefox browser on raspberry pie /arm device
力扣1037. 有效的回旋镖
随时随地查看远程试验数据与记录——IPEhub2与IPEmotion APP
The cost of returning tables in MySQL
from .cv2 import * ImportError: libGL.so.1: cannot open shared object file: No such file or direc
Boot - Prometheus push gateway use
mysql: error while loading shared libraries: libtinfo. so. 5: cannot open shared object file: No such
Installation and testing of pyflink
[牛客] B-完全平方数
迈动互联中标北京人寿保险,助推客户提升品牌价值
The MySQL database in Alibaba cloud was attacked, and finally the data was found
STM32开发资料链接分享
OSPF configuration command of Huawei equipment
批量获取中国所有行政区域经边界纬度坐标(到县区级别)
重上吹麻滩——段芝堂创始人翟立冬游记
省市区三级坐标边界数据csv转JSON
【批處理DOS-CMD命令-匯總和小結】-字符串搜索、查找、篩選命令(find、findstr),Find和findstr的區別和辨析
Can the system hibernation file be deleted? How to delete the system hibernation file