begin implementing k8s config for telegram-bot-api
This commit is contained in:
parent
1b46462051
commit
5bc4c47145
1 changed files with 39 additions and 0 deletions
39
k8s/05_tg-stateful-set.yml
Normal file
39
k8s/05_tg-stateful-set.yml
Normal file
|
|
@ -0,0 +1,39 @@
|
||||||
|
apiVersion: apps/v1
|
||||||
|
kind: StatefulSet
|
||||||
|
metadata:
|
||||||
|
name: tg
|
||||||
|
namespace: mk-dl-bot
|
||||||
|
spec:
|
||||||
|
selector:
|
||||||
|
matchLabels:
|
||||||
|
app: mk-dl-bot
|
||||||
|
service: tg
|
||||||
|
serviceName: "tg"
|
||||||
|
replicas: 1
|
||||||
|
template:
|
||||||
|
metadata:
|
||||||
|
labels:
|
||||||
|
app: mk-dl-bot
|
||||||
|
service: tg
|
||||||
|
spec:
|
||||||
|
terminationGracePeriodSeconds: 10
|
||||||
|
containers:
|
||||||
|
- name: tg
|
||||||
|
image: mykola2312/telegram-bot-api:latest
|
||||||
|
ports:
|
||||||
|
- containerPort: 8081
|
||||||
|
name: tg
|
||||||
|
volumeMounts:
|
||||||
|
- name: tg-data
|
||||||
|
mountPath: /app
|
||||||
|
volumeClaimTemplates:
|
||||||
|
- metadata:
|
||||||
|
name: tg-data
|
||||||
|
spec:
|
||||||
|
accessModes:
|
||||||
|
- ReadWriteOnce
|
||||||
|
resources:
|
||||||
|
requests:
|
||||||
|
storage: 5Gi
|
||||||
|
---
|
||||||
|
|
||||||
Loading…
Add table
Reference in a new issue