From 41fb358312f8236d967048c2faf7f5370dc3f9fe Mon Sep 17 00:00:00 2001
From: xeruf <27jf@pm.me>
Date: Wed, 27 Sep 2023 11:49:01 +0100
Subject: [PATCH] apps/code: open port 22 for gitea

---
 basic/apps/code/ingress-gitea.yaml |  7 +++++++
 basic/apps/code/metallb-gitea.yaml | 18 ++++++++++++++++++
 2 files changed, 25 insertions(+)
 create mode 100644 basic/apps/code/ingress-gitea.yaml
 create mode 100644 basic/apps/code/metallb-gitea.yaml

diff --git a/basic/apps/code/ingress-gitea.yaml b/basic/apps/code/ingress-gitea.yaml
new file mode 100644
index 0000000..e4a33a9
--- /dev/null
+++ b/basic/apps/code/ingress-gitea.yaml
@@ -0,0 +1,7 @@
+apiVersion: v1
+kind: ConfigMap
+metadata:
+  name: tcp-services
+  namespace: stackspout
+data:
+  22: "gitea:22"
diff --git a/basic/apps/code/metallb-gitea.yaml b/basic/apps/code/metallb-gitea.yaml
new file mode 100644
index 0000000..176a611
--- /dev/null
+++ b/basic/apps/code/metallb-gitea.yaml
@@ -0,0 +1,18 @@
+# https://metallb.org/usage/
+apiVersion: v1
+kind: Service
+metadata:
+  name: gitea-ssh
+  namespace: stackspout
+  annotations:
+    metallb.universe.tf/allow-shared-ip: "share-ipv4"
+spec:
+  type: LoadBalancer
+  loadBalancerIP: "${ip_address}"
+  ports:
+    - name: ssh
+      protocol: TCP
+      port: 22
+      targetPort: 22
+  selector:
+    app: gitea
-- 
GitLab