Skip to content
This repository has been archived by the owner on Jan 8, 2024. It is now read-only.

Revert redis back into deployment #740

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
67 changes: 67 additions & 0 deletions kubernetes/templates/redis.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
apiVersion: v1
kind: Service
metadata:
name: redis
labels:
app: redis
spec:
ports:
- name: "6379"
port: 6379
selector:
app: redis
---
apiVersion: apps/v1
kind: Deployment
metadata:
labels:
app: redis
name: redis
spec:
replicas: 1
selector:
matchLabels:
app: redis
template:
metadata:
labels:
app: redis
spec:
containers:
- image: redis:3.0
imagePullPolicy: IfNotPresent
name: redis
resources:
{{ if .Values.less_resources }}
requests:
cpu: 50m
memory: 500M
{{ else }}
limits:
memory: 2G
cpu: 500m
requests:
memory: 1G
cpu: 500m
{{ end }}
ports:
- containerPort: 6379
protocol: TCP
volumeMounts:
- mountPath: /data
name: redis-data
volumes:
- name: redis-data
persistentVolumeClaim:
claimName: redis-data
---
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: redis-data
spec:
accessModes:
- ReadWriteOnce
resources:
requests:
storage: 2Gi