@@ -0,0 +1,60 @@
+apiVersion: apps/v1
+kind: Deployment
+metadata:
+ name: gogs-default
+spec:
+ replicas: 3
+ selector:
+ matchLabels:
+ app: gogs-default
+ template:
+ metadata:
+ labels:
+ spec:
+ nodeSelector:
+ "beta.kubernetes.io/os": linux
+ containers:
+ - name: gogs-default
+ image: gogs/gogs
+ resources:
+ requests:
+ cpu: 100m
+ memory: 256Mi
+ ports:
+ - containerPort: 3000
+ volumeMounts:
+ - name: gogs-pvc
+ mountPath: /data
+ volumes:
+ persistentVolumeClaim:
+ claimName: gogs-pvc
+---
+apiVersion: v1
+kind: PersistentVolumeClaim
+ name: gogs-pvc
+ accessModes:
+ - ReadWriteOnce
+ storage: 10Gi
+
+kind: Service
+ name: gogs-svc
+ - port: 3000
+ protocol: TCP
+ type: LoadBalancer
@@ -0,0 +1,58 @@
+ name: mysql
+ - port: 3306
+ app: mysql
+ clusterIP: None
+ strategy:
+ type: Recreate
+ - image: mysql:5.6
+ env:
+ # Use secret in real usage
+ - name: MYSQL_ROOT_PASSWORD
+ value: d5022a
+ - containerPort: 3306
+ - name: mysql-pvc
+ mountPath: /var/lib/mysql
+ claimName: mysql-pvc
+ name: mysql-pvc