diff --git a/apps/grocy/deployment.yaml b/apps/grocy/deployment.yaml index e69de29..8c7ebb8 100644 --- a/apps/grocy/deployment.yaml +++ b/apps/grocy/deployment.yaml @@ -0,0 +1,41 @@ +apiVersion: apps/v1 +kind: Deployment +metadata: + name: grocy + namespace: grocy + labels: + app: grocy +spec: + replicas: 1 + selector: + matchLabels: + app: grocy + template: + metadata: + labels: + app: grocy + spec: + containers: + - name: grocy + image: lscr.io/linuxserver/grocy:latest + resources: + limits: + cpu: 500m + memory: 512Mi + requests: + cpu: 20m + memory: 64Mi + ports: + - containerPort: 80 + name: web + env: + - name: TZ + value: Europe/Berlin + volumeMounts: + - name: data + mountPath: "/config" + readOnly: false + volumes: + - name: data + persistentVolumeClaim: + claimName: grocy-data diff --git a/apps/grocy/ingress.yaml b/apps/grocy/ingress.yaml new file mode 100644 index 0000000..e48af58 --- /dev/null +++ b/apps/grocy/ingress.yaml @@ -0,0 +1,22 @@ +apiVersion: networking.k8s.io/v1 +kind: Ingress +metadata: + name: grocy + annotations: + cert-manager.io/cluster-issuer: letsencrypt-prod +spec: + rules: + - host: grocy.chaosdorf.space + http: + paths: + - path: / + pathType: Prefix + backend: + service: + name: grocy + port: + number: 80 + tls: + - secretName: ingress-tls + hosts: + - grocy.chaosdorf.space diff --git a/apps/grocy/kustomization.yaml b/apps/grocy/kustomization.yaml new file mode 100644 index 0000000..51f5ecc --- /dev/null +++ b/apps/grocy/kustomization.yaml @@ -0,0 +1,8 @@ +apiVersion: kustomize.config.k8s.io/v1beta1 +kind: Kustomization +namespace: grocy +resources: +- namespace.yaml +- volumes.yaml +- deployment.yaml +- service.yaml diff --git a/apps/grocy/namespace.yaml b/apps/grocy/namespace.yaml new file mode 100644 index 0000000..6ff555d --- /dev/null +++ b/apps/grocy/namespace.yaml @@ -0,0 +1,4 @@ +apiVersion: v1 +kind: Namespace +metadata: + name: grocy diff --git a/apps/grocy/service.yaml b/apps/grocy/service.yaml new file mode 100644 index 0000000..a888a57 --- /dev/null +++ b/apps/grocy/service.yaml @@ -0,0 +1,14 @@ +apiVersion: v1 +kind: Service +metadata: + name: grocy + namespace: grocy +spec: + type: ClusterIP + selector: + app: grocy + ports: + - name: web + protocol: TCP + port: 80 + targetPort: web diff --git a/apps/grocy/volumes.yaml b/apps/grocy/volumes.yaml new file mode 100644 index 0000000..db1c048 --- /dev/null +++ b/apps/grocy/volumes.yaml @@ -0,0 +1,12 @@ +apiVersion: v1 +kind: PersistentVolumeClaim +metadata: + name: grocy-data + namespace: grocy +spec: + storageClassName: ceph-filesystem + accessModes: + - ReadWriteMany + resources: + requests: + storage: 6Gi