From 24753266ee0785caa4247e59d6da6bdd7f237e8d Mon Sep 17 00:00:00 2001 From: pierre Date: Wed, 19 Jun 2024 13:42:21 +0100 Subject: [PATCH] :boom: add all the files --- opentrashmail.kube.yaml | 70 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 70 insertions(+) create mode 100644 opentrashmail.kube.yaml diff --git a/opentrashmail.kube.yaml b/opentrashmail.kube.yaml new file mode 100644 index 0000000..9eaaa0e --- /dev/null +++ b/opentrashmail.kube.yaml @@ -0,0 +1,70 @@ +apiVersion: v1 +kind: Namespace +metadata: + name: opentrashmail +--- +apiVersion: apps/v1 +kind: Deployment +metadata: + name: opentrashmail + namespace: opentrashmail +spec: + replicas: 1 + selector: + matchLabels: + app: opentrashmail + template: + metadata: + labels: + app: opentrashmail + spec: + nodeName: kube-master + containers: + - image: hascheksolutions/opentrashmail:1 + imagePullPolicy: IfNotPresent + name: opentrashmail + ports: + - containerPort: 80 + name: otm-port + - containerPort: 25 + name: otm-smtp-port + volumeMounts: + - name: otm-config + mountPath: /var/www/opentrashmail/data + env: + - name: URL + value: "https://localhost:80" + + volumes: + - name: otm-config + hostPath: + path: /opt/kubernetes/opentrashmail_kube/config +--- +apiVersion: v1 +kind: Service +metadata: + name: opentrashmail + namespace: opentrashmail +spec: + ports: + - port: 80 + targetPort: otm-port + protocol: TCP + selector: + app: opentrashmail + +--- +apiVersion: v1 +kind: Service +metadata: + name: otm-smtp + namespace: opentrashmail +spec: + ports: + - port: 25 + targetPort: otm-smtp-port + protocol: TCP + nodePort: 30025 + type: NodePort + selector: + app: opentrashmail