mirror of
https://github.com/tgbot-collection/ytdlbot.git
synced 2024-11-15 20:54:50 +08:00
81 lines
1.4 KiB
YAML
81 lines
1.4 KiB
YAML
|
apiVersion: v1
|
||
|
kind: PersistentVolumeClaim
|
||
|
metadata:
|
||
|
creationTimestamp: null
|
||
|
labels:
|
||
|
ytdl: mariadb-pvc
|
||
|
name: mariadb-pvc
|
||
|
namespace: ytdl
|
||
|
spec:
|
||
|
accessModes:
|
||
|
- ReadWriteOnce
|
||
|
storageClassName: longhorn
|
||
|
resources:
|
||
|
requests:
|
||
|
storage: 10Gi
|
||
|
status: {}
|
||
|
|
||
|
---
|
||
|
apiVersion: apps/v1
|
||
|
kind: Deployment
|
||
|
metadata:
|
||
|
annotations:
|
||
|
creationTimestamp: null
|
||
|
labels:
|
||
|
ytdl: mariadb
|
||
|
name: mariadb
|
||
|
namespace: ytdl
|
||
|
spec:
|
||
|
replicas: 1
|
||
|
selector:
|
||
|
matchLabels:
|
||
|
ytdl: mariadb
|
||
|
strategy:
|
||
|
type: Recreate
|
||
|
template:
|
||
|
metadata:
|
||
|
creationTimestamp: null
|
||
|
labels:
|
||
|
ytdl: mariadb
|
||
|
spec:
|
||
|
containers:
|
||
|
- env:
|
||
|
- name: MYSQL_ROOT_PASSWORD
|
||
|
value: ro0tP4sSworD
|
||
|
- name: MYSQL_DATABASE
|
||
|
value: ytdl
|
||
|
image: mariadb:latest
|
||
|
name: mariadb
|
||
|
ports:
|
||
|
- containerPort: 3306
|
||
|
resources: {}
|
||
|
volumeMounts:
|
||
|
- mountPath: /var/lib/mysql
|
||
|
name: "mariadb-persistent-storage"
|
||
|
restartPolicy: Always
|
||
|
volumes:
|
||
|
- name: mariadb-persistent-storage
|
||
|
persistentVolumeClaim:
|
||
|
claimName: mariadb-pvc
|
||
|
status: {}
|
||
|
|
||
|
---
|
||
|
apiVersion: v1
|
||
|
kind: Service
|
||
|
metadata:
|
||
|
creationTimestamp: null
|
||
|
labels:
|
||
|
ytdl: mariadb
|
||
|
name: mariadb-svc
|
||
|
namespace: ytdl
|
||
|
spec:
|
||
|
ports:
|
||
|
- name: "3306"
|
||
|
port: 3306
|
||
|
targetPort: 3306
|
||
|
selector:
|
||
|
ytdl: mariadb
|
||
|
status:
|
||
|
loadBalancer: {}
|
||
|
|