In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-09-23 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >
Share
Shulou(Shulou.com)06/01 Report--
[root@mytest mariadb10.3] # cat Dockerfile
FROM centos
MAINTAINER xingzhenxiang 20190610
ADD MariaDB.repo / etc/yum.repos.d/MariaDB.repo
RUN yum install-y MariaDB-server
ENV PASSWD 123456
RUN yum clean all
RUN chmod 777-R / var/lib/mysql
ADD run.sh /
RUN chmod 755 / run.sh
# Expose ports.
VOLUME / var/lib/mysql
EXPOSE 3306
CMD ["/ run.sh"]
[root@mytest mariadb10.3] # cat run.sh
#! / bin/bash
Cp / usr/share/mysql/mysql.server / etc/init.d/mysql.server
Mysql_install_db-user=mysql
# sleep 20
/ etc/init.d/mysql.server start
Sleep 20
Mysql-uroot-e "update mysql.user set host='%',password=password ($PASSWD) where host='::1'; flush privileges;"
Sleep 20
Tail-f / var/lib/mysql/ `hostname`.err
[root@mytest mariadb10.3] # ll
Total dosage 16
-rw-r--r-- 1 root root 287 June 10 14:43 Dockerfile
-rw-r--r-- 1 root root 6 June 6 10:26 MariaDB.repo
-rw-r--r-- 1 root root 316 June 10 16:02 run.sh
-rw-r--r-- 1 root root 109 June 6 12:28 run.sh.bak
[root@mytest mariadb10.3] # cat MariaDB.repo
[mariadb]
Name = MariaDB
Baseurl = https://mirrors.ustc.edu.cn/mariadb/yum/10.3/centos7-amd64/
Gpgkey= https://mirrors.ustc.edu.cn/mariadb/yum/RPM-GPG-KEY-MariaDB
Gpgcheck=1
[root@mytest mariadb10.3] #
Docker build-t mytest/mariadb10.3.
Docker run-d-p 3306 name mariadb5 mytest/mariadb10.3 3306-v / data/dockertest/mysql:/var/lib/mysql-- name mariadb5 mytest/mariadb10.3
Mysql-h227.0.0.1-uroot-P3306-p123456
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
The market share of Chrome browser on the desktop has exceeded 70%, and users are complaining about
The world's first 2nm mobile chip: Samsung Exynos 2600 is ready for mass production.According to a r
A US federal judge has ruled that Google can keep its Chrome browser, but it will be prohibited from
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
About us Contact us Product review car news thenatureplanet
More Form oMedia: AutoTimes. Bestcoffee. SL News. Jarebook. Coffee Hunters. Sundaily. Modezone. NNB. Coffee. Game News. FrontStreet. GGAMEN
© 2024 shulou.com SLNews company. All rights reserved.