surf
This commit is contained in:
1 parent
174a963ce0
commit
0e78da4d2b
5 files changed
+222
-29
No files matched your search
Executable
+76
@@ -0,0 +1,76 @@
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: mariadb
|
||||
namespace: surf
|
||||
spec:
|
||||
replicas: 1
|
||||
selector:
|
||||
matchLabels:
|
||||
app: mariadb
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
app: mariadb
|
||||
spec:
|
||||
containers:
|
||||
- name: mariadb
|
||||
image: mariadb:12
|
||||
imagePullPolicy: IfNotPresent
|
||||
ports:
|
||||
- containerPort: 3306
|
||||
env:
|
||||
- name: MYSQL_ROOT_PASSWORD
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
name: surf
|
||||
key: MYSQL_ROOT_PASSWORD
|
||||
- name: MYSQL_DATABASE
|
||||
value: "shavit"
|
||||
volumeMounts:
|
||||
- name: mariadb-data
|
||||
mountPath: /var/lib/mysql
|
||||
volumes:
|
||||
- name: mariadb-data
|
||||
persistentVolumeClaim:
|
||||
claimName: mariadb-data
|
||||
|
||||
---
|
||||
|
||||
# -----------------------------------------------------------------------
|
||||
# SERVICE
|
||||
# -----------------------------------------------------------------------
|
||||
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: mariadb
|
||||
namespace: surf
|
||||
spec:
|
||||
type: ClusterIP
|
||||
selector:
|
||||
app: mariadb
|
||||
ports:
|
||||
- protocol: TCP
|
||||
port: 3306
|
||||
targetPort: 3306
|
||||
|
||||
---
|
||||
|
||||
# -----------------------------------------------------------------------
|
||||
# VOLUMES
|
||||
# -----------------------------------------------------------------------
|
||||
|
||||
kind: PersistentVolumeClaim
|
||||
apiVersion: v1
|
||||
metadata:
|
||||
name: mariadb-data
|
||||
namespace: surf
|
||||
spec:
|
||||
storageClassName: zfs-fast
|
||||
accessModes:
|
||||
- ReadWriteOnce
|
||||
resources:
|
||||
requests:
|
||||
storage: 1Gi
|
||||
|
||||
Executable
+115
@@ -0,0 +1,115 @@
|
||||
---
|
||||
|
||||
apiVersion: v1
|
||||
kind: Namespace
|
||||
metadata:
|
||||
name: surf
|
||||
|
||||
|
||||
# -----------------------------------------------------------------------
|
||||
# VOLUMES
|
||||
# -----------------------------------------------------------------------
|
||||
|
||||
---
|
||||
|
||||
kind: PersistentVolumeClaim
|
||||
apiVersion: v1
|
||||
metadata:
|
||||
name: cssds-data
|
||||
namespace: surf
|
||||
spec:
|
||||
storageClassName: zfs-fast
|
||||
accessModes:
|
||||
- ReadWriteOnce
|
||||
resources:
|
||||
requests:
|
||||
storage: 10Gi
|
||||
|
||||
---
|
||||
|
||||
kind: PersistentVolumeClaim
|
||||
apiVersion: v1
|
||||
metadata:
|
||||
name: tf2ds-data
|
||||
namespace: surf
|
||||
spec:
|
||||
storageClassName: zfs-fast
|
||||
accessModes:
|
||||
- ReadWriteOnce
|
||||
resources:
|
||||
requests:
|
||||
storage: 10Gi
|
||||
|
||||
---
|
||||
|
||||
# -----------------------------------------------------------------------
|
||||
# DEPLOYMENT
|
||||
# -----------------------------------------------------------------------
|
||||
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: megastructure-surf
|
||||
namespace: surf
|
||||
spec:
|
||||
replicas: 1
|
||||
selector:
|
||||
matchLabels:
|
||||
app: megastructure-surf
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
app: megastructure-surf
|
||||
spec:
|
||||
containers:
|
||||
- name: megastructure-surf
|
||||
image: registry.ntwl.xyz/megastructure-surf
|
||||
imagePullPolicy: Always
|
||||
command: ["sleep", "100000000"]
|
||||
ports:
|
||||
- containerPort: 27015
|
||||
- containerPort: 27005
|
||||
envFrom:
|
||||
- secretRef:
|
||||
name: surf
|
||||
volumeMounts:
|
||||
- name: cssds
|
||||
mountPath: /home/steam/cssds
|
||||
- name: tf2ds
|
||||
mountPath: /home/steam/tf2ds
|
||||
volumes:
|
||||
- name: cssds
|
||||
persistentVolumeClaim:
|
||||
claimName: cssds-data
|
||||
- name: tf2ds
|
||||
persistentVolumeClaim:
|
||||
claimName: tf2ds-data
|
||||
|
||||
---
|
||||
|
||||
# -----------------------------------------------------------------------
|
||||
# SERVICES
|
||||
# -----------------------------------------------------------------------
|
||||
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: megastructure-surf
|
||||
namespace: surf
|
||||
spec:
|
||||
type: NodePort
|
||||
selector:
|
||||
app: megastructure-surf
|
||||
ports:
|
||||
- name: game-port
|
||||
protocol: UDP
|
||||
port: 27015
|
||||
targetPort: 27015
|
||||
nodePort: 32015
|
||||
- name: client-port
|
||||
protocol: UDP
|
||||
port: 27005
|
||||
targetPort: 27005
|
||||
nodePort: 32005
|
||||
|
||||
---
|
||||
Reference in new issue
Block a user