prod init dir
parent
708f6270ee
commit
c5c56e22ba
|
@ -56,20 +56,23 @@ spec:
|
||||||
app: mysql-m
|
app: mysql-m
|
||||||
spec:
|
spec:
|
||||||
initContainers:
|
initContainers:
|
||||||
- name: init
|
- name: init
|
||||||
image: busybox
|
image: busybox
|
||||||
imagePullPolicy: IfNotPresent
|
imagePullPolicy: IfNotPresent
|
||||||
command:
|
command:
|
||||||
- sh
|
- sh
|
||||||
- -c
|
- -c
|
||||||
- |
|
- |
|
||||||
sysctl -w net.ipv4.tcp_keepalive_time=300
|
sysctl -w net.ipv4.tcp_keepalive_time=300
|
||||||
sysctl -w net.ipv4.tcp_keepalive_intvl=10
|
sysctl -w net.ipv4.tcp_keepalive_intvl=10
|
||||||
sysctl -w net.ipv4.tcp_keepalive_probes=3
|
sysctl -w net.ipv4.tcp_keepalive_probes=3
|
||||||
mkdir -p /var/lib/mysql/{logs,data}
|
mkdir -p /var/lib/mysql/{logs,data}
|
||||||
chown -R 999:999 /var/lib/mysql
|
chown -R 999:999 /var/lib/mysql
|
||||||
securityContext:
|
securityContext:
|
||||||
privileged: true
|
privileged: true
|
||||||
|
volumeMounts:
|
||||||
|
- name: mysql-m
|
||||||
|
mountPath: /var/lib/mysql
|
||||||
containers:
|
containers:
|
||||||
- name: mysql
|
- name: mysql
|
||||||
image: mysql:8.0.33
|
image: mysql:8.0.33
|
||||||
|
|
|
@ -67,9 +67,12 @@ spec:
|
||||||
sysctl -w net.ipv4.tcp_keepalive_intvl=10
|
sysctl -w net.ipv4.tcp_keepalive_intvl=10
|
||||||
sysctl -w net.ipv4.tcp_keepalive_probes=3
|
sysctl -w net.ipv4.tcp_keepalive_probes=3
|
||||||
mkdir -p /var/lib/mysql/{logs,data}
|
mkdir -p /var/lib/mysql/{logs,data}
|
||||||
chown -R mysql.mysql /var/lib/mysql
|
chown -R 999:999 /var/lib/mysql
|
||||||
securityContext:
|
securityContext:
|
||||||
privileged: true
|
privileged: true
|
||||||
|
volumeMounts:
|
||||||
|
- name: mysql-m
|
||||||
|
mountPath: /var/lib/mysql
|
||||||
containers:
|
containers:
|
||||||
- name: mysql
|
- name: mysql
|
||||||
image: mysql:8.0.33
|
image: mysql:8.0.33
|
||||||
|
|
Loading…
Reference in New Issue