add infra app minio

This commit is contained in:
2024-07-18 21:11:16 +10:00
parent 446cc3051e
commit bece0ca7ec
7 changed files with 164 additions and 0 deletions

View File

@@ -0,0 +1,12 @@
{
"appName": "minio",
"userGivenName": "minio",
"namespace": "minio",
"destNamespace": "minio",
"destServer": "https://kubernetes.default.svc",
"srcPath": "infrastructures/minio/env/k3s-cluster",
"srcRepoURL": "https://github.com/3dwardch3ng/home-cluster-ops.git",
"srcTargetRevision": "",
"labels": null,
"annotations": null
}

View File

@@ -0,0 +1,51 @@
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: minio-ingress
namespace: minio
annotations:
nginx.ingress.kubernetes.io/ssl-redirect: "false"
nginx.ingress.kubernetes.io/use-regex: "true"
spec:
ingressClassName: nginx
rules:
- host: "minio.cluster.edward.sydney"
http:
paths:
- pathType: Prefix
path: "/"
backend:
service:
name: minio
port:
number: 19001
- host: "api.minio.cluster.edward.sydney"
http:
paths:
- pathType: Prefix
path: "/"
backend:
service:
name: minio
port:
number: 19000
- host: "minio.cluster.local"
http:
paths:
- pathType: Prefix
path: "/"
backend:
service:
name: minio
port:
number: 19001
- host: "api.minio.cluster.local"
http:
paths:
- pathType: Prefix
path: "/"
backend:
service:
name: minio
port:
number: 19000

View File

@@ -0,0 +1,6 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
resources:
- ./volume.yaml
- ../../base
- ./ingress.yaml

View File

@@ -0,0 +1,18 @@
clusterDomain: minio.cluster.edward.sydney
auth:
existingSecret: "minio-secrets"
rootUserSecretKey: "root_user"
rootPasswordSecretKey: "root_password"
nodeSelector:
kubernetes.io/hostname: k3s-cluster-node-2
service:
ports:
api: 19000
console: 19001
persistence:
existingClaim: "minio-pvc"
containerSecurityContext:
runAsUser: 1000
runAsGroup: 1000
podSecurityContext:
fsGroup: 1000

View File

@@ -0,0 +1,46 @@
apiVersion: v1
kind: PersistentVolume
metadata:
name: minio-pv
namespace: minio
labels:
type: local
spec:
storageClassName: local-path
volumeMode: Filesystem
capacity:
storage: 256Gi
accessModes:
- ReadWriteOnce
persistentVolumeReclaimPolicy: Retain
local:
path: "/mnt/nfs/AppData/minio"
claimRef:
apiVersion: v1
kind: PersistentVolumeClaim
name: minio-pvc
namespace: minio
nodeAffinity:
required:
nodeSelectorTerms:
- matchExpressions:
- key: kubernetes.io/hostname
operator: In
values:
- rpi5-cluster-node-2
---
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: minio-pvc
namespace: minio
labels:
name: minio-pvc
spec:
storageClassName: local-path
volumeMode: Filesystem
accessModes:
- ReadWriteOnce
resources:
requests:
storage: 256Gi