Clean up operatorlib related stuff

This commit is contained in:
2023-08-16 10:39:20 +03:00
parent 49412781ea
commit af83e1783b
25 changed files with 301 additions and 282 deletions

View File

@@ -1,7 +1,8 @@
# minio-clusters
This namespace houses Minio clusters managed by
[Codemowers' Operator Bundle](https://github.com/codemowers/operator-bundle)
This is namespace for Minio clusters managed by Codemowers' sample
[minio-bucket-operator](https://github.com/codemowers/operatorlib/tree/main/samples/minio-bucket-operator)
which is deployed via [ArgoCD](https://argocd.k-space.ee/applications/argocd/minio-bucket-operator)
To update bump the `image` tag for the classes and issue:

13
minio-clusters/cert.yaml Normal file
View File

@@ -0,0 +1,13 @@
---
apiVersion: cert-manager.io/v1
kind: Certificate
metadata:
name: wildcard-tls
namespace: minio-clusters
spec:
dnsNames:
- "*.minio-clusters.k-space.ee"
issuerRef:
kind: ClusterIssuer
name: default
secretName: wildcard-tls

View File

@@ -1,51 +1,23 @@
---
apiVersion: codemowers.io/v1alpha1
kind: ClusterBucketClass
apiVersion: codemowers.cloud/v1beta1
kind: MinioBucketClass
metadata:
name: dedicated
annotations:
kubernetes.io/description: "Dedicated Minio cluster"
spec:
targetNamespace: minio-clusters
description: "Dedicated Minio clusters"
reclaimPolicy: Retain
replicas: 4
storageClass: minio
podSpec:
containers:
- name: minio
env:
- name: MINIO_PROMETHEUS_AUTH_TYPE
value: public
image: minio/minio:RELEASE.2023-02-17T17-52-43Z
args:
- server
- --address
- 0.0.0.0:9000
- --console-address
- 0.0.0.0:9001
ports:
- containerPort: 9000
name: http
- containerPort: 9001
name: console
readinessProbe:
httpGet:
path: /minio/health/ready
port: 9000
initialDelaySeconds: 2
periodSeconds: 5
resources:
requests:
cpu: 300m
memory: 1Gi
limits:
cpu: 4000m
memory: 2Gi
volumeMounts:
- name: data
mountPath: /data
image: docker.io/minio/minio:RELEASE.2023-07-18T17-49-40Z@sha256:8879cd0b0c4087817430e21be3ad909d60e9da62fac3e8d9368d9fde51279229
imagePullPolicy: IfNotPresent
nodeSelector:
dedicated: storage
tolerations:
- effect: NoSchedule
key: dedicated
operator: Equal
value: storage
- effect: NoSchedule
key: dedicated
operator: Equal
value: storage

View File

@@ -1,12 +1,13 @@
---
apiVersion: codemowers.io/v1alpha1
kind: ClusterBucketClass
apiVersion: codemowers.cloud/v1beta1
kind: MinioBucketClass
metadata:
name: external
annotations:
kubernetes.io/description: "External Minio cluster"
spec:
description: "Minio instance running on the ZFS storage box"
targetNamespace: minio-clusters
targetCluster: external
reclaimPolicy: Retain
shared: true
---
apiVersion: v1
kind: Service
@@ -18,8 +19,7 @@ spec:
ports:
- name: http
protocol: TCP
port: 80
targetPort: 9000
port: 9000
type: ExternalName
---
apiVersion: v1
@@ -32,8 +32,7 @@ spec:
ports:
- name: http
protocol: TCP
port: 80
targetPort: 9001
port: 9001
type: ExternalName
---
apiVersion: networking.k8s.io/v1
@@ -48,7 +47,7 @@ metadata:
external-dns.alpha.kubernetes.io/target: traefik.k-space.ee
spec:
rules:
- host: minio-cluster-external.k-space.ee
- host: external.minio-clusters.k-space.ee
http:
paths:
- pathType: Prefix
@@ -61,6 +60,7 @@ spec:
tls:
- hosts:
- "*.k-space.ee"
secretName: wildcard-tls
---
apiVersion: networking.k8s.io/v1
kind: Ingress
@@ -74,7 +74,7 @@ metadata:
external-dns.alpha.kubernetes.io/target: traefik.k-space.ee
spec:
rules:
- host: minio-cluster-external-console.k-space.ee
- host: external-console.minio-clusters.k-space.ee
http:
paths:
- pathType: Prefix
@@ -87,3 +87,4 @@ spec:
tls:
- hosts:
- "*.k-space.ee"
secretName: wildcard-tls

View File

@@ -1,55 +1,27 @@
---
apiVersion: codemowers.io/v1alpha1
kind: ClusterBucketClass
apiVersion: codemowers.cloud/v1beta1
kind: MinioBucketClass
metadata:
name: shared
annotations:
kubernetes.io/description: "Shared Minio cluster"
spec:
description: "Shared Minio cluster"
targetNamespace: minio-clusters
targetCluster: shared
storageClass: minio
reclaimPolicy: Retain
shared: true
replicas: 4
storageClass: minio
podSpec:
containers:
- name: minio
env:
- name: MINIO_PROMETHEUS_AUTH_TYPE
value: public
image: minio/minio:RELEASE.2023-02-17T17-52-43Z
args:
- server
- --address
- 0.0.0.0:9000
- --console-address
- 0.0.0.0:9001
ports:
- containerPort: 9000
name: http
- containerPort: 9001
name: console
readinessProbe:
httpGet:
path: /minio/health/ready
port: 9000
initialDelaySeconds: 2
periodSeconds: 5
resources:
requests:
cpu: 300m
memory: 1Gi
limits:
cpu: 4000m
memory: 2Gi
volumeMounts:
- name: data
mountPath: /data
image: docker.io/minio/minio:RELEASE.2023-07-18T17-49-40Z@sha256:8879cd0b0c4087817430e21be3ad909d60e9da62fac3e8d9368d9fde51279229
imagePullPolicy: IfNotPresent
nodeSelector:
dedicated: storage
tolerations:
- effect: NoSchedule
key: dedicated
operator: Equal
value: storage
- effect: NoSchedule
key: dedicated
operator: Equal
value: storage
---
apiVersion: networking.k8s.io/v1
kind: Ingress
@@ -63,7 +35,7 @@ metadata:
external-dns.alpha.kubernetes.io/target: traefik.k-space.ee
spec:
rules:
- host: minio-cluster-shared.k-space.ee
- host: shared.minio-clusters.k-space.ee
http:
paths:
- pathType: Prefix
@@ -76,6 +48,7 @@ spec:
tls:
- hosts:
- "*.k-space.ee"
secretName: wildcard-tls
---
apiVersion: networking.k8s.io/v1
kind: Ingress
@@ -89,7 +62,7 @@ metadata:
external-dns.alpha.kubernetes.io/target: traefik.k-space.ee
spec:
rules:
- host: minio-cluster-shared-console.k-space.ee
- host: shared-console.minio-clusters.k-space.ee
http:
paths:
- pathType: Prefix
@@ -102,3 +75,4 @@ spec:
tls:
- hosts:
- "*.k-space.ee"
secretName: wildcard-tls