diff --git a/apps/application.yaml b/apps/application.yaml deleted file mode 100644 index cc6df1f..0000000 --- a/apps/application.yaml +++ /dev/null @@ -1,32 +0,0 @@ -apiVersion: argoproj.io/v1alpha1 -kind: Application -metadata: - name: factorio - namespace: argocd -spec: - project: default - source: - repoURL: https://sqljames.github.io/factorio-server-charts - chart: factorio-server-charts - targetRevision: "*" - helm: - valueFiles: - - values.yaml - kustomize: - patches: - - target: - kind: Deployment - name: factorio-factorio-server-charts - patch: | - - op: replace - path: /spec/template/spec/hostNetwork - value: false - - op: remove - path: /spec/template/spec/hostPorts - destination: - server: https://kubernetes.default.svc - namespace: factorio - syncPolicy: - automated: - selfHeal: true - prune: true diff --git a/apps/factorio/deployment.yaml b/apps/factorio/deployment.yaml new file mode 100644 index 0000000..43481c4 --- /dev/null +++ b/apps/factorio/deployment.yaml @@ -0,0 +1,40 @@ +apiVersion: apps/v1 +kind: Deployment +metadata: + name: factorio + namespace: factorio +spec: + replicas: 1 + selector: + matchLabels: + app: factorio + template: + metadata: + labels: + app: factorio + spec: + affinity: + nodeAffinity: + requiredDuringSchedulingIgnoredDuringExecution: + nodeSelectorTerms: + - matchExpressions: + - key: workload + operator: In + values: + - Games + containers: + - name: factorio + image: factoriotools/factorio:latest + ports: + - containerPort: 34197 + protocol: UDP + env: + - name: SERVER_NAME + value: "UWU-Danta" + volumeMounts: + - name: data + mountPath: /factorio + volumes: + - name: data + persistentVolumeClaim: + claimName: factorio-data diff --git a/apps/factorio/pve.yaml b/apps/factorio/pve.yaml new file mode 100644 index 0000000..bbba8ea --- /dev/null +++ b/apps/factorio/pve.yaml @@ -0,0 +1,11 @@ +apiVersion: v1 +kind: PersistentVolumeClaim +metadata: + name: factorio-data + namespace: factorio +spec: + accessModes: + - ReadWriteOnce + resources: + requests: + storage: 5Gi diff --git a/apps/factorio/service.yaml b/apps/factorio/service.yaml new file mode 100644 index 0000000..4ccc7df --- /dev/null +++ b/apps/factorio/service.yaml @@ -0,0 +1,13 @@ +apiVersion: v1 +kind: Service +metadata: + name: factorio-service + namespace: factorio +spec: + type: LoadBalancer + selector: + app: factorio + ports: + - port: 34197 + targetPort: 34197 + protocol: UDP diff --git a/apps/values.yaml b/apps/values.yaml deleted file mode 100644 index 4a9beb5..0000000 --- a/apps/values.yaml +++ /dev/null @@ -1,35 +0,0 @@ -# cluster-state/apps/factorio/values.yaml - -service - type: LoadBalancer - port: 34197 - targetPort: 34197 - -hostNetworkEnabled: false -hostPort: null - -# Sorge dafür, dass der Pod auf dem Game-Node landet -affinity: - nodeAffinity: - requiredDuringSchedulingIgnoredDuringExecution: - nodeSelectorTerms: - - matchExpressions: - - key: workload - operator: In - values: - - Games # Das Label, das du wahrscheinlich für server03 gesetzt hast - -# Factorio Networking -service: - type: LoadBalancer - port: 34197 - protocol: UDP - -# Persistence (Speichert deine Map auf dem Host) -persistence: - enabled: true - storageClass: "local-path" # Oder deine spezifische StorageClass - size: 5Gi - -factorio: - serverName: "UWU-Danta"