From bbf10df554ee4fa967a421d9b369658b49f62c19 Mon Sep 17 00:00:00 2001 From: Tyler Perkins Date: Fri, 10 Nov 2023 15:41:30 -0500 Subject: [PATCH] Add back factorio --- games/factorio/factorio-deployment.yaml | 29 +++++++++++++++++++++++++ games/factorio/factorio-pvc.yaml | 13 +++++++++++ games/games-service.yaml | 19 ++++++++++++++++ 3 files changed, 61 insertions(+) create mode 100644 games/factorio/factorio-deployment.yaml create mode 100644 games/factorio/factorio-pvc.yaml create mode 100644 games/games-service.yaml diff --git a/games/factorio/factorio-deployment.yaml b/games/factorio/factorio-deployment.yaml new file mode 100644 index 0000000..b45dd93 --- /dev/null +++ b/games/factorio/factorio-deployment.yaml @@ -0,0 +1,29 @@ +apiVersion: apps/v1 +kind: Deployment +metadata: + name: factorio + namespace: games-ns +spec: + replicas: 1 + selector: + matchLabels: + app: games + template: + metadata: + labels: + app: games + spec: + containers: + - name: factorio + image: factoriotools/factorio:stable + ports: + - containerPort: 34179 + - containerPort: 27015 + volumeMounts: + - name: factorio-save + mountPath: /factorio + volumes: + - name: factorio-save + persistentVolumeClaim: + claimName: factorio-pvc + diff --git a/games/factorio/factorio-pvc.yaml b/games/factorio/factorio-pvc.yaml new file mode 100644 index 0000000..049b3dc --- /dev/null +++ b/games/factorio/factorio-pvc.yaml @@ -0,0 +1,13 @@ +apiVersion: v1 +kind: PersistentVolumeClaim +metadata: + name: factorio-pvc + namespace: games-ns +spec: + accessModes: + - ReadWriteOnce + storageClassName: longhorn + resources: + requests: + storage: 8Gi + diff --git a/games/games-service.yaml b/games/games-service.yaml new file mode 100644 index 0000000..9066cc9 --- /dev/null +++ b/games/games-service.yaml @@ -0,0 +1,19 @@ +apiVersion: v1 +kind: Service +metadata: + name: games-service + namespace: games-ns +spec: + selector: + app: games + ports: + - name: factorio + protocol: UDP + port: 34197 + targetPort: 34197 + - name: factorio-tui + protocol: TCP + port: 27015 + targetPort: 27015 + type: LoadBalancer +