You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

116 lines
2.5 KiB

# Deployment description
apiVersion: apps/v1
kind: Deployment
metadata:
name: checkmk
namespace: infra-environment
labels:
app: checkmk
spec:
strategy:
type: Recreate
replicas: 1
selector:
matchLabels:
app: checkmk
template:
metadata:
labels:
app: checkmk
spec:
containers:
- name: checkmk
image: checkmk/check-mk-raw:2.0.0
args: # fix an issue with special characters - see https://confluence.atlassian.com/jirakb/error-failed-to-send-request-to-the-knowledge-base-server-943525845.html
- /bin/sh
- -c
- sleep 5h
resources:
requests:
memory: "1Gi"
cpu: "100m"
limits:
memory: "2Gi"
cpu: "4"
ports:
- containerPort: 5000
name: checkmk-http
protocol: TCP
volumeMounts:
- mountPath: /omd/sites
name: checkmk-sites-pv-dev
- mountPath: /omd/sites_tmp
name: checkmk-pv-dev
volumes:
- name: checkmk-pv-dev
persistentVolumeClaim:
claimName: checkmk-pvc-dev
- name: checkmk-sites-pv-dev
persistentVolumeClaim:
claimName: checkmk-sites-pvc-dev
---
# Persistent Volume Claim description
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: checkmk-pvc-dev
namespace: infra-environment
labels:
app: checkmk-dev
spec:
storageClassName: longhorn
accessModes:
- ReadWriteOnce
resources:
requests:
storage: 11Gi
---
# Persistent Volume Claim description
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: checkmk-sites-pvc-dev
namespace: infra-environment
labels:
app: checkmk-dev
spec:
storageClassName: longhorn
accessModes:
- ReadWriteOnce
resources:
requests:
storage: 10Gi
---
# Service Description
apiVersion: v1
kind: Service
metadata:
name: checkmk
namespace: infra-environment
spec:
selector:
app: checkmk
ports:
- name: checkmk-http
port: 5000
targetPort: checkmk-http
type: NodePort
---
# Ingress description
apiVersion: networking.k8s.io/v1beta1
kind: Ingress
metadata:
name: checkmk-ingress
namespace: infra-environment
annotations:
kubernetes.io/ingress.class: "traefik"
spec:
rules:
- host: checkmk.k3s.semapp.lan
http:
paths:
- path: /
backend:
serviceName: checkmk
servicePort: 5000