当前位置:网站首页>Creation of kubernetes mysql8
Creation of kubernetes mysql8
2022-07-07 20:08:00 【Li Weilun】
apiVersion: apps/v1
kind: Deployment
metadata:
name: mysql1
namespace: default
labels:
app: mysql1
spec:
replicas: 1
selector:
matchLabels:
app: mysql1
template:
metadata:
labels:
app: mysql1
spec:
affinity:
nodeAffinity:
requiredDuringSchedulingIgnoredDuringExecution:
nodeSelectorTerms:
- matchExpressions:
- key: ip
operator: In
values:
- 172.16.12.104
containers:
- name: mysql1
envFrom:
- secretRef:
name: mysql1
image: mysql:8
args:
- "--lower_case_table_names=1"
imagePullPolicy: IfNotPresent
ports:
- containerPort: 3306
name: 3306tcp
protocol: TCP
volumeMounts:
- mountPath: /var/lib/mysql
name: mysql1data
volumes:
- hostPath:
path: /opt/mysql1/data/
type: DirectoryOrCreate
name: mysql1data
restartPolicy: Always
mysql8 There's an important feature , Case sensitivity can only be completed when the database is initialized , So we're going to be here args Join in –lower_case_table_names=1, That is, the case is not sensitive
Create user ,mysql8 You need to create a user before you can assign permissions
use mysql;create user 'szxy_test'@'%' identified by 'Liweilun1208.';
If you forget when creating users with mysql_native_password
Log in with this user and report authentication plugin 'caching_sha2_password' cannot be loaded;
alter user 'szxy_test'@'%' identified with mysql_native_password by 'Liweilun1208.';
Assign permissions
grant all privileges on *.* to 'szxy_test'@'%' with grant option;
边栏推荐
- Make this crmeb single merchant wechat mall system popular, so easy to use!
- torch.nn.functional.pad(input, pad, mode=‘constant‘, value=None)记录
- c语言如何判定是32位系统还是64位系统
- 【剑指offer】剑指 Offer II 012. 左右两边子数组的和相等
- Ways to improve the utilization of openeuler resources 01: Introduction
- 力扣674. 最长连续递增序列
- 841. 字符串哈希
- PMP對工作有益嗎?怎麼選擇靠譜平臺讓備考更省心省力!!!
- Chapter 9 Yunji datacanvas was rated as 36 krypton "the hard core technology enterprise most concerned by investors"
- 如何在软件研发阶段落地安全实践
猜你喜欢
mock. JS returns an array from the optional data in the object array
论文解读(ValidUtil)《Rethinking the Setting of Semi-supervised Learning on Graphs》
开源重器!九章云极DataCanvas公司YLearn因果学习开源项目即将发布!
Automatic classification of defective photovoltaic module cells in electroluminescence images-論文閱讀筆記
Automatic classification of defective photovoltaic module cells in electroluminescence images-论文阅读笔记
有了ST7008, 蓝牙测试完全拿捏住了
PMP對工作有益嗎?怎麼選擇靠譜平臺讓備考更省心省力!!!
Flink并行度和Slot详解
LeetCode_7_5
ASP. Net kindergarten chain management system source code
随机推荐
Force buckle 643 Subarray maximum average I
ASP. Net kindergarten chain management system source code
LeetCode力扣(剑指offer 36-39)36. 二叉搜索树与双向链表37. 序列化二叉树38. 字符串的排列39. 数组中出现次数超过一半的数字
gorilla官方:golang开websocket client的示例代码
Vulnhub's funfox2
Is PMP beneficial to work? How to choose a reliable platform to make it easier to prepare for the exam!!!
力扣 459. 重复的子字符串
Dynamic addition of El upload upload component; El upload dynamically uploads files; El upload distinguishes which component uploads the file.
Mysql, sqlserver Oracle database connection mode
LeetCode_ 7_ five
JVM GC garbage collection brief
使用高斯Redis实现二级索引
有了ST7008, 蓝牙测试完全拿捏住了
Force buckle 674 Longest continuous increasing sequence
Leetcode force buckle (Sword finger offer 36-39) 36 Binary search tree and bidirectional linked list 37 Serialize binary tree 38 Arrangement of strings 39 Numbers that appear more than half of the tim
841. String hash
841. 字符串哈希
The project manager's "eight interview questions" is equal to a meeting
Notes...
【剑指offer】剑指 Offer II 012. 左右两边子数组的和相等