-
Notifications
You must be signed in to change notification settings - Fork 470
/
Copy pathdeployment.yaml
55 lines (55 loc) · 1.83 KB
/
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
---
apiVersion: apps/v1
kind: Deployment
metadata:
name: redis-commander
annotations:
# Tell Kubernetes to apply the AppArmor or SecComp profile "runtime/default". (whatever is used)
# Note that this is ignored if the Kubernetes node is not running version 1.4 or greater.
# and fails if AppArmor enabled but profile not found (may happens on borked k8s installs only)
# set to "unconfined" to disable AppArmor (first annotation) or SecComp (second annotation)
container.apparmor.security.beta.kubernetes.io/redis-commander: runtime/default
container.security.alpha.kubernetes.io/redis-commander: runtime/default
spec:
replicas: 1
selector:
matchLabels:
app: redis-commander
template:
metadata:
labels:
app: redis-commander
tier: backend
spec:
automountServiceAccountToken: false
containers:
- name: redis-commander
image: ghcr.io/joeferner/redis-commander
imagePullPolicy: Always
env:
- name: REDIS_HOSTS
value: "instance1:redis:6379"
- name: K8S_SIGTERM
value: "1"
ports:
- name: redis-commander
containerPort: 8081
livenessProbe:
httpGet:
path: /favicon.png
port: 8081
initialDelaySeconds: 10
timeoutSeconds: 5
# adapt to your needs base on data stored inside redis (number of keys and size of biggest keys)
# or comment out for less secure installation
resources:
limits:
cpu: "500m"
memory: "512M"
securityContext:
runAsNonRoot: true
readOnlyRootFilesystem: false
allowPrivilegeEscalation: false
capabilities:
drop:
- ALL