-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmlflow-mysql-deployment.yaml
executable file
·75 lines (75 loc) · 1.42 KB
/
mlflow-mysql-deployment.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
apiVersion: apps/v1
kind: Deployment
metadata:
name: mlflowdb
namespace: default
labels:
app: mlflow
component: mysql
spec:
replicas: 1
strategy:
type: Recreate
selector:
matchLabels:
app: mlflow
component: mysql
template:
metadata:
name: mlflow-mysql
labels:
app: mlflow
component: mysql
annotations:
sidecar.istio.io/inject: "false"
spec:
containers:
- name: mlflowdb
image: mysql/mysql-server:5.7.28
env:
- name: MYSQL_DATABASE
value: 'mlflow_database'
- name: MYSQL_USER
value: 'mlflow_user'
- name: MYSQL_PASSWORD
value: 'mlflow'
- name: MYSQL_ROOT_PASSWORD
value: 'mysql'
ports:
- containerPort: 3306
name: mlflowdb
volumeMounts:
- mountPath: /var/lib/mysql
name: mlflow-mysql
volumes:
- name: mlflow-mysql
persistentVolumeClaim:
claimName: mlflow-mysql
---
apiVersion: v1
kind: Service
metadata:
name: mlflow-mysql
labels:
app: mlflow
component: mysql
spec:
type: ClusterIP
ports:
- port: 3306
protocol: TCP
name: mlflow-mysql
selector:
app: mlflow
component: mysql
---
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: mlflow-mysql
spec:
accessModes:
- ReadWriteOnce
resources:
requests:
storage: 10Gi