From 7ced224112e821f7e41d92e2a79f2594799dc838 Mon Sep 17 00:00:00 2001 From: Ravind Kumar Date: Thu, 5 Oct 2023 13:38:16 -0400 Subject: [PATCH 1/4] DOCS-1007: Create sync pattern to pull in the CRD during releases --- Makefile | 3 + source/includes/k8s/ext-tenant-crd.md | 1603 +++++++++++++++++++++++++ source/index.rst | 1 + source/reference/operator-crd.rst | 21 + source/url-excludes.yaml | 4 + sync-minio-operator-crd.sh | 17 + 6 files changed, 1649 insertions(+) create mode 100644 source/includes/k8s/ext-tenant-crd.md create mode 100644 source/reference/operator-crd.rst create mode 100755 sync-minio-operator-crd.sh diff --git a/Makefile b/Makefile index 0513b41c..5c9017cb 100644 --- a/Makefile +++ b/Makefile @@ -236,6 +236,9 @@ sync-minio-version: sync-sdks: @(./sync-docs.sh) +sync-operator-crd: + @(./sync-minio-operator-crd.sh) + # Can probably safely remove this at some point sync-deps: # C++ and Rust repos do not have any releases yet. diff --git a/source/includes/k8s/ext-tenant-crd.md b/source/includes/k8s/ext-tenant-crd.md new file mode 100644 index 00000000..fa7db227 --- /dev/null +++ b/source/includes/k8s/ext-tenant-crd.md @@ -0,0 +1,1603 @@ + + +# Operator CRD v2 Reference + +Package v2 - This page provides a quick automatically generated +reference for the MinIO Operator `Operator CRD v2 Reference` CRD. For more +complete documentation on the MinIO Operator CRD, see [MinIO Kubernetes +Documentation](https://min.io/docs/minio/kubernetes/upstream/index.html). + +The `Operator CRD v2 Reference` API was released with the v4.0.0 MinIO Operator. +The MinIO Operator automatically converts existing tenants using the +`/v1` API to `/v2`. + +- [Tenant](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-tenant) + +## Bucket + +Bucket describes the default created buckets + +- [TenantSpec](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-tenantspec) + + ++++ + + + + + + + + + + + + + + + + + + + + +
FieldDescription

name +string

region +string

objectLock +boolean

+ +## CertificateConfig + +CertificateConfig (`certConfig`) defines controlling attributes +associated to any TLS certificate automatically generated by the +Operator as part of tenant creation. These fields have no effect if +`spec.autoCert: false`. + +- [TenantSpec](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-tenantspec) + + ++++ + + + + + + + + + + + + + + + + + + + + +
FieldDescription

commonName +string

Optional
+The CommonName or CN attribute to associate to +automatically generated TLS certificates.
+

organizationName +string array

Optional
+Specify one or more OrganizationName or O +attributes to associate to automatically generated TLS +certificates.
+

dnsNames +string array

Optional
+Specify one or more x.509 Subject Alternative Names (SAN) to associate +to automatically generated TLS certificates. MinIO Server pods use SNI +to determine which certificate to respond with based on the requested +hostname.

+ +## CertificateStatus + +CertificateStatus keeps track of all the certificates managed by the +operator + +- [TenantStatus](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-tenantstatus) + + ++++ + + + + + + + + + + + + + + + + +
FieldDescription

autoCertEnabled +boolean

AutoCertEnabled registers whether we +know if the tenant has autocert enabled

customCertificates +CustomCertificates

Provides the output of the +client, minio, and`minioCAs` custom TLS +certificates manually added to the Operator.

+ +## CustomCertificateConfig + +CustomCertificateConfig (`customCertificateConfig`) provides attributes +associated of the TLS certificates manually added to the Operator as +part of tenant creation. These fields contain no data if there are no +custom TLS certificates. + +- [CustomCertificates](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-customcertificates) + +## CustomCertificates + +CustomCertificates (`customCertificates`) provides groupings of the TLS +certificates manually added to the Operator as part of tenant creation. +These fields contain no data if there are no custom TLS certificates. + +- [CertificateStatus](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-certificatestatus) + + ++++ + + + + + + + + + + + + + + + + + + + + +
FieldDescription

client +CustomCertificateConfig +array

Optional
+Client

minio +CustomCertificateConfig +array

Optional
+Minio

minioCAs +CustomCertificateConfig +array

Optional
+Certificate Authorities

+ +## ExposeServices + +ExposeServices (`exposeServices`) defines the exposure of the MinIO +object storage and Console services. + +- [TenantSpec](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-tenantspec) + + ++++ + + + + + + + + + + + + + + + + +
FieldDescription

minio +boolean

Optional
+Directs the Operator to expose the MinIO service. Defaults to +true.
+

console +boolean

Optional
+Directs the Operator to expose the MinIO Console service. Defaults to +true.
+

+ +## Features + +Features (`features`) - Object describing which MinIO features to +enable/disable in the MinIO Tenant. + +- [TenantSpec](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-tenantspec) + + ++++ + + + + + + + + + + + + + + + + + + + + +
FieldDescription

bucketDNS +boolean

Optional
+Specify true to allow clients to access buckets using the +DNS path <bucket>.minio.default.svc.cluster.local. +Defaults to false.

domains +TenantDomains

Optional
+Specify a list of domains used to access MinIO and Console.

enableSFTP +boolean

Optional
+Starts minio server with SFTP support

+ +## HealthStatus (string) + +HealthStatus represents whether the tenant is healthy, with decreased +service or offline + +- [TenantStatus](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-tenantstatus) + +## KESConfig + +KESConfig (`kes`) defines the configuration of the [MinIO Key Encryption +Service](https://github.com/minio/kes) (KES) StatefulSet deployed as +part of the MinIO Tenant. KES supports Server-Side Encryption of objects +using an external Key Management Service (KMS). + +- [TenantSpec](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-tenantspec) + + ++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FieldDescription

replicas +integer

Optional
+Specify the number of replica KES pods to deploy in the tenant. Defaults +to 2.

image +string

Optional
+

imagePullPolicy +PullPolicy

Optional
+The pull policy for the MinIO Docker image. Specify one of the +following:
+* Always
+* Never
+* IfNotPresent (Default)
+Refer to the Kubernetes documentation for details https://kubernetes.io/docs/concepts/containers/images#updating-images

serviceAccountName +string

Optional
+The Kubernetes +Service Account to use for running MinIO KES pods created as part of +the Tenant.
+

kesSecret +LocalObjectReference

Required
+Specify a Kubernetes +opaque secret which contains environment variables to use for +setting up the MinIO KES service.
+See the MinIO +Operator console-secret.yaml for an example.

externalCertSecret +LocalCertificateReference

Optional
+Enables TLS with SNI support on each MinIO KES pod in the tenant. If +externalCertSecret is omitted and +spec.requestAutoCert is set to false, MinIO +KES pods deploy without TLS enabled.
+Specify a Kubernetes +TLS secret. The MinIO Operator copies the specified certificate to +every MinIO pod in the tenant. When the MinIO pod/service responds to a +TLS connection request, it uses SNI to select the certificate with +matching subjectAlternativeName.
+Specify an object containing the following fields:
+* - name - The name of the Kubernetes secret containing the +TLS certificate.
+* - type - Specify kubernetes.io/tls
+See the MinIO +Operator CRD reference for examples and more complete documentation +on configuring TLS for MinIO Tenants.

clientCertSecret +LocalCertificateReference

Optional
+Specify a a Kubernetes +TLS secret containing a custom root Certificate Authority and x.509 +certificate to use for performing mTLS authentication with an external +Key Management Service, such as Hashicorp Vault.
+Specify an object containing the following fields:
+* - name - The name of the Kubernetes secret containing the +Certificate Authority and x.509 Certificate.
+* - type - Specify kubernetes.io/tls
+

gcpCredentialSecretName +string

Optional
+Specify the GCP default credentials to be used for KES to authenticate +to GCP key store

gcpWorkloadIdentityPool +string

Optional
+Specify the name of the workload identity pool (This is required for +generating service account token)

annotations +object (keys:string, values:string)

Optional
+If provided, use these annotations for KES Object Meta +annotations

labels +object (keys:string, values:string)

Optional
+If provided, use these labels for KES Object Meta labels

resources +ResourceRequirements

Optional
+Object specification for specifying CPU and memory resource +allocations or limits in the MinIO tenant.
+

nodeSelector +object (keys:string, values:string)

Optional
+The filter for the Operator to apply when selecting which nodes on which +to deploy MinIO KES pods. The Operator only selects those nodes whose +labels match the specified selector.
+See the Kubernetes documentation on Assigning +Pods to Nodes for more information.

tolerations +Toleration +array

Optional
+Specify one or more Kubernetes +tolerations to apply to MinIO KES pods.

affinity +Affinity

Optional
+Specify node affinity, pod affinity, and pod anti-affinity for the KES +pods.
+

topologySpreadConstraints +TopologySpreadConstraint +array

Optional
+Specify one or more Kubernetes +Topology Spread Constraints to apply to pods deployed in the MinIO +pool.

keyName +string

Optional
+If provided, use this as the name of the key that KES creates on the KMS +backend

securityContext +PodSecurityContext

Specify the Security +Context of MinIO KES pods. The Operator supports only the following +pod security fields:
+* fsGroup
+* fsGroupChangePolicy
+* runAsGroup
+* runAsNonRoot
+* runAsUser
+* seLinuxOptions
+

env +EnvVar +array

Optional
+If provided, the MinIO Operator adds the specified environment variables +when deploying the KES resource.

+ +## LocalCertificateReference + +LocalCertificateReference (`externalCertSecret`, +`externalCaCertSecret`,`clientCertSecret`) contains a Kubernetes secret +containing TLS certificates or Certificate Authority files for use with +enabling TLS in the MinIO Tenant. + +- [KESConfig](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-kesconfig) + +- [TenantSpec](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-tenantspec) + + ++++ + + + + + + + + + + + + + + + + +
FieldDescription

name +string

Required
+The name of the Kubernetes secret containing the TLS certificate or +Certificate Authority file.
+

type +string

Required
+The type of Kubernetes secret. Specify +kubernetes.io/tls
+

+ +## Logging + +Logging describes Logging for MinIO tenants. + +- [TenantSpec](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-tenantspec) + + ++++ + + + + + + + + + + + + + + + + + + + + +
FieldDescription

json +boolean

anonymous +boolean

quiet +boolean

+ +## Pool + +Pool (`pools`) defines a MinIO server pool on a Tenant. Each pool +consists of a set of MinIO server pods which "pool" their storage +resources for supporting object storage and retrieval requests. Each +server pool is independent of all others and supports horizontal scaling +of available storage resources in the MinIO Tenant. +See the [MinIO Operator +CRD](https://min.io/docs/minio/kubernetes/upstream/operations/install-deploy-manage/deploy-minio-tenant.html#procedure-command-line) +reference for the `pools` object for examples and more complete +documentation. + +- [TenantSpec](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-tenantspec) + + ++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FieldDescription

name +string

Optional
+Specify the name of the pool. The Operator automatically generates the +pool name if this field is omitted.

servers +integer

Required The number of +MinIO server pods to deploy in the pool. The minimum value is +2. The MinIO Operator requires a minimum of 4 +volumes per pool. Specifically, the result of +pools.servers X pools.volumesPerServer must be greater than +4.
+

volumesPerServer +integer

Required
+The number of Persistent Volume Claims to generate for each MinIO server +pod in the pool.
+The MinIO Operator requires a minimum of 4 volumes per +pool. Specifically, the result of +pools.servers X pools.volumesPerServer must be greater than +4.
+

volumeClaimTemplate +PersistentVolumeClaim

Required
+Specify the configuration options for the MinIO Operator to use when +generating Persistent Volume Claims for the MinIO tenant.
+

resources +ResourceRequirements

Optional
+Object specification for specifying CPU and memory resource +allocations or limits in the MinIO tenant.
+

nodeSelector +object (keys:string, values:string)

Optional
+The filter for the Operator to apply when selecting which nodes on which +to deploy pods in the pool. The Operator only selects those nodes whose +labels match the specified selector.
+See the Kubernetes documentation on Assigning +Pods to Nodes for more information.

affinity +Affinity

Optional
+Specify node affinity, pod affinity, and pod anti-affinity for pods in +the MinIO pool.
+

tolerations +Toleration +array

Optional
+Specify one or more Kubernetes +tolerations to apply to pods deployed in the MinIO pool.

topologySpreadConstraints +TopologySpreadConstraint +array

Optional
+Specify one or more Kubernetes +Topology Spread Constraints to apply to pods deployed in the MinIO +pool.

securityContext +PodSecurityContext

Optional
+Specify the Security +Context of pods in the pool. The Operator supports only the +following pod security fields:
+* fsGroup
+* fsGroupChangePolicy
+* runAsGroup
+* runAsNonRoot
+* runAsUser
+

containerSecurityContext +SecurityContext

Specify the Security +Context of containers in the pool. The Operator supports only the +following container security fields:
+* runAsGroup
+* runAsNonRoot
+* runAsUser
+

annotations +object (keys:string, values:string)

Optional
+Specify custom labels and annotations to append to the Pool. +Optional
+If provided, use these annotations for the Pool Objects Meta annotations +(Statefulset and Pod template)

labels +object (keys:string, values:string)

Optional
+If provided, use these labels for the Pool Objects Meta annotations +(Statefulset and Pod template)

runtimeClassName +string

Optional
+If provided, each pod on the Statefulset will run with the specified +RuntimeClassName, for more info https://kubernetes.io/docs/concepts/containers/runtime-class/

+ +## PoolState (string) + +PoolState represents the state of a pool + +- [PoolStatus](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-poolstatus) + +## PoolStatus + +PoolStatus keeps track of all the pools and their current state + +- [TenantStatus](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-tenantstatus) + + ++++ + + + + + + + + + + + + + + + + + + + + +
FieldDescription

ssName +string

state +PoolState

legacySecurityContext +boolean

LegacySecurityContext stands for Legacy +SecurityContext. It represents that these pool was created before v4.2.3 +when we introduced the default securityContext as non-root, thus we +should keep running this Pool without a Security Context

+ +## ServiceMetadata + +ServiceMetadata (`serviceMetadata`) defines custom labels and +annotations for the MinIO Object Storage service and/or MinIO Console +service. + +- [TenantSpec](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-tenantspec) + + ++++ + + + + + + + + + + + + + + + + + + + + + + + + +
FieldDescription

minioServiceLabels +object (keys:string, values:string)

Optional
+If provided, append these labels to the MinIO service

minioServiceAnnotations +object (keys:string, values:string)

Optional
+If provided, append these annotations to the MinIO service

consoleServiceLabels +object (keys:string, values:string)

Optional
+If provided, append these labels to the Console service

consoleServiceAnnotations +object (keys:string, values:string)

Optional
+If provided, append these annotations to the Console service

+ +## SideCars + +SideCars (`sidecars`) defines a list of containers that the Operator +attaches to each MinIO server pods in the `pool`. + +- [TenantSpec](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-tenantspec) + + ++++ + + + + + + + + + + + + + + + + + + + + + + + + +
FieldDescription

containers +Container +array

Optional
+List of containers to run inside the Pod

volumeClaimTemplates +PersistentVolumeClaim +array

Optional
+volumeClaimTemplates is a list of claims that pods are allowed to +reference. The StatefulSet controller is responsible for mapping network +identities to claims in a way that maintains the identity of a pod. +Every claim in this list must have at least one matching (by name) +volumeMount in one container in the template. A claim in this list takes +precedence over any volumes in the template, with the same +name.

volumes +Volume +array

Optional
+List of volumes that can be mounted by containers belonging to the pod. +More info: https://kubernetes.io/docs/concepts/storage/volumes

resources +ResourceRequirements

Optional
+sidecar’s Resource, initcontainer will use that if set.

+ +## Tenant + +Tenant is a [Kubernetes +object](https://kubernetes.io/docs/concepts/overview/working-with-objects/kubernetes-objects/) +describing a MinIO Tenant. + +- [TenantList](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-tenantlist) + + ++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FieldDescription

apiVersion +string

Operator CRD v2 Reference

kind +string

Tenant

metadata +ObjectMeta

Refer to Kubernetes API documentation +for fields of metadata.

scheduler +TenantScheduler

spec +TenantSpec

Required
+The root field for the MinIO Tenant object.

+ +## TenantDomains + +TenantDomains (`domains`) - List of domains used to access the tenant +from outside the kubernetes clusters. this will only configure MinIO for +the domains listed, but external DNS configuration is still needed. The +listed domains should include schema and port if any is used, i.e. + + +- [Features](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-features) + + ++++ + + + + + + + + + + + + + + + + +
FieldDescription

minio +string array

List of Domains used by MinIO. This +will enable DNS style access to the object store where the bucket name +is inferred from a subdomain in the domain.

console +string

Domain used to expose the MinIO +Console, this will configure the redirect on MinIO when visiting from +the browser If Console is exposed via a subpath, the domain should +include it, i.e. https://console.domain.com:8123/subpath/

+ +## TenantScheduler + +TenantScheduler (`scheduler`) - Object describing Kubernetes Scheduler +to use for deploying the MinIO Tenant. + +- [Tenant](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-tenant) + + ++++ + + + + + + + + + + + + +
FieldDescription

name +string

Optional
+Specify the name of the Kubernetes +scheduler to be used to schedule Tenant pods

+ +## TenantSpec + +TenantSpec (`spec`) defines the configuration of a MinIO Tenant +object. +The following parameters are specific to the `Operator CRD v2 Reference` MinIO CRD +API `spec` definition added as part of the MinIO Operator v4.0.0. +For more complete documentation on this object, see the [MinIO +Kubernetes +Documentation](https://min.io/docs/minio/kubernetes/upstream/operations/installation.html). + +- [Tenant](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-tenant) + + ++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FieldDescription

pools +Pool +array

Required
+An array of objects describing each MinIO server pool deployed in the +MinIO Tenant. Each pool consists of a set of MinIO server pods which +"pool" their storage resources for supporting object storage and +retrieval requests. Each server pool is independent of all others and +supports horizontal scaling of available storage resources in the MinIO +Tenant.
+The MinIO Tenant spec must have at least +one element in the pools array.
+See the MinIO +Operator CRD reference for the pools object for +examples and more complete documentation.

image +string

Optional
+

imagePullSecret +LocalObjectReference

Optional
+Specify the secret key to use for pulling images from a private Docker +repository.
+

podManagementPolicy +PodManagementPolicyType

Optional
+Pod Management Policy for pod created by StatefulSet

credsSecret +LocalObjectReference

optional
+Specify a Kubernetes +opaque secret to use for setting the MinIO root access key and +secret key. Specify the secret as name: <secret>. The +Kubernetes secret must contain the following fields:
+* data.accesskey - The access key for the root +credentials
+* data.secretkey - The secret key for the root +credentials
+

env +EnvVar +array

Optional
+If provided, the MinIO Operator adds the specified environment variables +when deploying the Tenant resource.

externalCertSecret +LocalCertificateReference +array

Optional
+Enables TLS with SNI support on each MinIO pod in the tenant. If +externalCertSecret is omitted and +requestAutoCert is set to false, the MinIO +Tenant deploys without TLS enabled.
+Specify an array of Kubernetes +TLS secrets. The MinIO Operator copies the specified certificates to +every MinIO server pod in the tenant. When the MinIO pod/service +responds to a TLS connection request, it uses SNI to select the +certificate with matching subjectAlternativeName.
+Each element in the externalCertSecret array is an object +containing the following fields:
+* - name - The name of the Kubernetes secret containing the +TLS certificate.
+* - type - Specify kubernetes.io/tls
+See the MinIO +Operator CRD reference for examples and more complete documentation +on configuring TLS for MinIO Tenants.

externalCaCertSecret +LocalCertificateReference +array

Optional
+Allows MinIO server pods to verify client TLS certificates signed by a +Certificate Authority not in the pod’s trust store.
+Specify an array of Kubernetes +TLS secrets. The MinIO Operator copies the specified certificates to +every MinIO server pod in the tenant.
+Each element in the externalCertSecret array is an object +containing the following fields:
+* - name - The name of the Kubernetes secret containing the +Certificate Authority.
+* - type - Specify kubernetes.io/tls.
+See the MinIO +Operator CRD reference for examples and more complete documentation +on configuring TLS for MinIO Tenants.

externalClientCertSecret +LocalCertificateReference

Optional
+Enables mTLS authentication between the MinIO Tenant pods and MinIO KES. +Required for enabling connectivity between the MinIO +Tenant and MinIO KES.
+Specify a Kubernetes +TLS secrets. The MinIO Operator copies the specified certificate to +every MinIO server pod in the tenant. The secret must +contain the following fields:
+* name - The name of the Kubernetes secret containing the +TLS certificate.
+* type - Specify kubernetes.io/tls
+The specified certificate must correspond to an +identity on the KES server. See the KES +Wiki for more information on KES identities.
+If deploying KES with the MinIO Operator, include the hash of the +certificate as part of the kes +object specification.
+See the MinIO +Operator CRD reference for examples and more complete documentation +on configuring TLS for MinIO Tenants.

externalClientCertSecrets +LocalCertificateReference +array

Optional
+Provide support for mounting additional client certificate into MinIO +Tenant pods Multiple client certificates will be mounted using the +following folder structure:
+* certs
+* * client-0
+* * * client.crt
+* * * client.key
+* * client-1
+* * * client.crt
+* * * client.key
+* * * client-2
+* * client.crt
+* * * client.key
+Specify a Kubernetes +TLS secrets. The MinIO Operator copies the specified certificate to +every MinIO server pod in the tenant that later can be referenced using +environment variables. The secret must contain the +following fields:
+* name - The name of the Kubernetes secret containing the +TLS certificate.
+* type - Specify kubernetes.io/tls
+

mountPath +string

Optional
+Mount path for MinIO volume (PV). Defaults to +/export

subPath +string

Optional
+Subpath inside mount path. This is the directory where MinIO stores +data. Default to ""` (empty)

requestAutoCert +boolean

Optional
+Enables using Kubernetes-based +TLS certificate generation and signing for pods and services in the +MinIO Tenant.
+* Specify true to explicitly enable automatic certificate +generate (Default).
+* Specify false to disable automatic certificate +generation.
+If requestAutoCert is set to false +and externalCertSecret is omitted, the +MinIO Tenant deploys without TLS enabled. See the MinIO +Operator CRD reference for examples and more complete documentation +on configuring TLS for MinIO Tenants.

liveness +Probe

Liveness Probe for container liveness. +Container will be restarted if the probe fails.

readiness +Probe

Readiness Probe for container +readiness. Container will be removed from service endpoints if the probe +fails.

startup +Probe

Startup Probe allows to configure a max +grace period for a pod to start before getting traffic routed to +it.

features +Features

S3 related features can be disabled or +enabled such as bucketDNS etc.

certConfig +CertificateConfig

Optional
+Enables setting the CommonName, Organization, +and dnsName attributes for all TLS certificates +automatically generated by the Operator. Configuring this object has no +effect if requestAutoCert is false.
+

kes +KESConfig

Optional
+Directs the MinIO Operator to deploy the MinIO Key Encryption Service +(KES) using the specified configuration. The MinIO KES supports +performing server-side encryption of objects on the MiNIO Tenant.
+

prometheusOperator +boolean

Optional
+Directs the MinIO Operator to use prometheus operator.
+Tenant scrape configuration will be added to prometheus managed by the +prometheus-operator.

serviceAccountName +string

Optional
+The Kubernetes +Service Account to use for running MinIO pods created as part of the +Tenant.
+

priorityClassName +string

Optional
+Indicates the Pod priority and therefore importance of a Pod relative to +other Pods in the cluster. This is applied to MinIO pods only.
+Refer Kubernetes Priority +Class documentation for more complete documentation.

imagePullPolicy +PullPolicy

Optional
+The pull policy for the MinIO Docker image. Specify one of the +following:
+* Always
+* Never
+* IfNotPresent (Default)
+Refer Kubernetes documentation for details https://kubernetes.io/docs/concepts/containers/images#updating-images

sideCars +SideCars

Optional
+A list of containers to run as sidecars along every MinIO Pod deployed +in the tenant.

exposeServices +ExposeServices

Optional
+Directs the Operator to expose the MinIO and/or Console services.
+

serviceMetadata +ServiceMetadata

Optional
+Specify custom labels and annotations to append to the MinIO service +and/or Console service.

users +LocalObjectReference +array

Optional
+An array of Kubernetes +opaque secrets to use for generating MinIO users during tenant +provisioning.
+Each element in the array is an object consisting of a key-value pair +name: <string>, where the <string> +references an opaque Kubernetes secret.
+Each referenced Kubernetes secret must include the following +fields:
+* CONSOLE_ACCESS_KEY - The "Username" for the MinIO +user
+* CONSOLE_SECRET_KEY - The "Password" for the MinIO +user
+The Operator creates each user with the consoleAdmin policy +by default. You can change the assigned policy after the Tenant +starts.
+

buckets +Bucket +array

Optional
+Create buckets when creating a new tenant. Skip if bucket with given +name already exists

logging +Logging

Optional
+Enable JSON, Anonymous logging for MinIO tenants.

configuration +LocalObjectReference

Optional
+Specify a secret that contains additional environment variable +configurations to be used for the MinIO pools. The secret is expected to +have a key named config.env containing all exported environment +variables for MinIO+

initContainers +Container +array

Optional
+Add custom initContainers to StatefulSet

additionalVolumes +Volume +array

Optional
+If provided, statefulset will add these volumes. You should set the +rules for the corresponding volumes and volume mounts. We will not test +this rule, k8s will show the result.

additionalVolumeMounts +VolumeMount +array

Optional
+If provided, statefulset will add these volumes. You should set the +rules for the corresponding volumes and volume mounts. We will not test +this rule, k8s will show the result.

+ +## TenantUsage + +TenantUsage are metrics regarding the usage and capacity of the tenant + +- [TenantStatus](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-tenantstatus) + + ++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FieldDescription

capacity +integer

Capacity the usage capacity of this +tenant in bytes.

rawCapacity +integer

Capacity the raw capacity of this +tenant in bytes.

usage +integer

Usage is how much data is managed by +MinIO in bytes.

rawUsage +integer

Usage is the raw usage on disks in +bytes.

tiers +TierUsage +array

Tiers includes the usage of individual +tiers in the tenant

+ +## TierUsage + +TierUsage represents the usage from a tier setup by the tenant + +- [TenantUsage](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-tenantusage) + + ++++ + + + + + + + + + + + + + + + + + + + + +
FieldDescription

Name +string

Name of the tier

Type +string

type of the tier

totalSize +integer

TotalSize usage of the tier

diff --git a/source/index.rst b/source/index.rst index ef54f66d..a8907e3a 100644 --- a/source/index.rst +++ b/source/index.rst @@ -209,6 +209,7 @@ Any file uploaded to ``play`` should be considered public and non-protected. MinIO Admin Client Integrations /reference/kubectl-minio-plugin + /reference/operator-crd .. toctree:: :titlesonly: diff --git a/source/reference/operator-crd.rst b/source/reference/operator-crd.rst new file mode 100644 index 00000000..8c80bdd4 --- /dev/null +++ b/source/reference/operator-crd.rst @@ -0,0 +1,21 @@ +.. _minio-operator-crd: + +================================ +MinIO Custom Resource Definition +================================ + +.. default-domain:: minio + +.. contents:: Table of Contents + :local: + :depth: 2 + + +The MinIO Operator installs a :kube-docs:`Custom Resource Definition (CRD) ` that describes a MinIO Tenant object. +The Operator uses this CRD for provisioning and managing Tenant resources within a Kubernetes cluster. + +This page documents the CRD reference for use in customizing Operator-deployed Tenants. +This documentation assumes familiarity with all referenced Kubernetes concepts, utilities, and procedures. + +.. include:: /includes/k8s/ext-tenant-crd.md + :parser: myst_parser.sphinx_ \ No newline at end of file diff --git a/source/url-excludes.yaml b/source/url-excludes.yaml index 7efe7756..65470b85 100644 --- a/source/url-excludes.yaml +++ b/source/url-excludes.yaml @@ -23,6 +23,7 @@ excludes: - 'reference/kubectl-minio-plugin/kubectl-minio-tenant-upgrade.rst' - 'reference/kubectl-minio-plugin/kubectl-minio-tenant.rst' - 'reference/kubectl-minio-plugin/kubectl-minio-version.rst' +- 'reference/operator-crd.rst' --- tag: macos excludes: @@ -39,6 +40,7 @@ excludes: - 'reference/minio-server*' - 'reference/minio-mc*' - 'reference/deprecated/*' +- 'reference/operator-crd.rst' - 'developers/*' - 'integrations/*' --- @@ -67,6 +69,7 @@ excludes: - 'reference/minio-server*' - 'reference/minio-mc*' - 'reference/deprecated/*' +- 'reference/operator-crd.rst' - 'developers/*' - 'integrations/*' --- @@ -89,6 +92,7 @@ excludes: - 'reference/minio-server*' - 'reference/minio-mc*' - 'reference/deprecated/*' +- 'reference/operator-crd.rst' - 'developers/*' - 'integrations/*' --- diff --git a/sync-minio-operator-crd.sh b/sync-minio-operator-crd.sh new file mode 100755 index 00000000..e2db5df3 --- /dev/null +++ b/sync-minio-operator-crd.sh @@ -0,0 +1,17 @@ +#!/bin/bash + +set -e + +function main() { + OPERATOR=$(curl --retry 10 -Ls -o /dev/null -w "%{url_effective}" https://github.com/minio/operator/releases/latest | sed "s/https:\/\/github.com\/minio\/operator\/releases\/tag\///" | sed "s/v//"); + + curl --retry 10 -Ls https://raw.githubusercontent.com/minio/operator/v${OPERATOR}/docs/tenant_crd.adoc | asciidoc -b docbook - | pandoc -f docbook -t markdown_strict - -o source/includes/k8s/ext-tenant-crd.md + + # To make the include nicer, this strips out the top H1 and reorders all headers thereafter + + sed -i 's%# API Reference%%g' source/includes/k8s/ext-tenant-crd.md + sed -i 's%minio.min.io/v2%Operator CRD v2 Reference%g' source/includes/k8s/ext-tenant-crd.md + sed -i 's%# % %g' source/includes/k8s/ext-tenant-crd.md +} + +main \ No newline at end of file From b999f2cc6573c9681e2f3292717dfb4e2ea38fe8 Mon Sep 17 00:00:00 2001 From: Ravind Kumar Date: Tue, 10 Oct 2023 14:33:42 -0400 Subject: [PATCH 2/4] Adding logic for Darwin sed --- sync-minio-operator-crd.sh | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/sync-minio-operator-crd.sh b/sync-minio-operator-crd.sh index e2db5df3..a0737060 100755 --- a/sync-minio-operator-crd.sh +++ b/sync-minio-operator-crd.sh @@ -9,9 +9,17 @@ function main() { # To make the include nicer, this strips out the top H1 and reorders all headers thereafter - sed -i 's%# API Reference%%g' source/includes/k8s/ext-tenant-crd.md - sed -i 's%minio.min.io/v2%Operator CRD v2 Reference%g' source/includes/k8s/ext-tenant-crd.md - sed -i 's%# % %g' source/includes/k8s/ext-tenant-crd.md + KNAME=$(uname -s) + case "${KNAME}" in + "Darwin") + sed -i '' 's%# API Reference%%g' source/includes/k8s/ext-tenant-crd.md + sed -i '' 's%minio.min.io/v2%Operator CRD v2 Reference%g' source/includes/k8s/ext-tenant-crd.md + sed -i '' 's%# % %g' source/includes/k8s/ext-tenant-crd.md;; + *) + sed -i 's%# API Reference%%g' source/includes/k8s/ext-tenant-crd.md + sed -i 's%minio.min.io/v2%Operator CRD v2 Reference%g' source/includes/k8s/ext-tenant-crd.md + sed -i 's%# % %g' source/includes/k8s/ext-tenant-crd.md;; + esac } main \ No newline at end of file From dffea64dae32168d719ddf0fb992a4d1dcd61aaf Mon Sep 17 00:00:00 2001 From: Ravind Kumar Date: Tue, 10 Oct 2023 16:16:47 -0400 Subject: [PATCH 3/4] Fixing links --- source/_static/scss/includes/_misc.scss | 10 +++ source/includes/k8s/ext-tenant-crd.md | 98 ++++++++++++------------- sync-minio-operator-crd.sh | 2 + 3 files changed, 61 insertions(+), 49 deletions(-) diff --git a/source/_static/scss/includes/_misc.scss b/source/_static/scss/includes/_misc.scss index b410bc1e..19d8fe86 100644 --- a/source/_static/scss/includes/_misc.scss +++ b/source/_static/scss/includes/_misc.scss @@ -370,4 +370,14 @@ figcaption { font-size: small; font-weight: bold; } +} + + +// --------------------------------------- +// Fixing table issues from asciidoc -> md +// --------------------------------------- + +table thead tr.header { + background-color: lightgray; + box-shadow: none; } \ No newline at end of file diff --git a/source/includes/k8s/ext-tenant-crd.md b/source/includes/k8s/ext-tenant-crd.md index fa7db227..9210876b 100644 --- a/source/includes/k8s/ext-tenant-crd.md +++ b/source/includes/k8s/ext-tenant-crd.md @@ -11,13 +11,13 @@ The `Operator CRD v2 Reference` API was released with the v4.0.0 MinIO Operator. The MinIO Operator automatically converts existing tenants using the `/v1` API to `/v2`. -- [Tenant](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-tenant) +- [Tenant](#tenant) ## Bucket Bucket describes the default created buckets -- [TenantSpec](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-tenantspec) +- [TenantSpec](#tenantspec) @@ -57,7 +57,7 @@ associated to any TLS certificate automatically generated by the Operator as part of tenant creation. These fields have no effect if `spec.autoCert: false`. -- [TenantSpec](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-tenantspec) +- [TenantSpec](#tenantspec)
@@ -107,7 +107,7 @@ hostname.

CertificateStatus keeps track of all the certificates managed by the operator -- [TenantStatus](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-tenantstatus) +- [TenantStatus](#tenantstatus)
@@ -132,7 +132,7 @@ know if the tenant has autocert enabled

+href="#customcertificates">CustomCertificates

@@ -147,7 +147,7 @@ associated of the TLS certificates manually added to the Operator as part of tenant creation. These fields contain no data if there are no custom TLS certificates. -- [CustomCertificates](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-customcertificates) +- [CustomCertificates](#customcertificates) ## CustomCertificates @@ -155,7 +155,7 @@ CustomCertificates (`customCertificates`) provides groupings of the TLS certificates manually added to the Operator as part of tenant creation. These fields contain no data if there are no custom TLS certificates. -- [CertificateStatus](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-certificatestatus) +- [CertificateStatus](#certificatestatus)

customCertificates CustomCertificates

Provides the output of the client, minio, and`minioCAs` custom TLS certificates manually added to the Operator.

@@ -172,7 +172,7 @@ These fields contain no data if there are no custom TLS certificates. @@ -180,7 +180,7 @@ Client

@@ -188,7 +188,7 @@ Minio

@@ -201,7 +201,7 @@ Certificate Authorities

ExposeServices (`exposeServices`) defines the exposure of the MinIO object storage and Console services. -- [TenantSpec](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-tenantspec) +- [TenantSpec](#tenantspec)

client CustomCertificateConfig +href="#customcertificateconfig">CustomCertificateConfig array

Optional
Client

minio CustomCertificateConfig +href="#customcertificateconfig">CustomCertificateConfig array

Optional
Minio

minioCAs CustomCertificateConfig +href="#customcertificateconfig">CustomCertificateConfig array

Optional
Certificate Authorities

@@ -239,7 +239,7 @@ Directs the Operator to expose the MinIO Console service. Defaults to Features (`features`) - Object describing which MinIO features to enable/disable in the MinIO Tenant. -- [TenantSpec](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-tenantspec) +- [TenantSpec](#tenantspec)
@@ -264,7 +264,7 @@ Defaults to false.

+href="#tenantdomains">TenantDomains

@@ -283,7 +283,7 @@ Starts minio server with SFTP support

HealthStatus represents whether the tenant is healthy, with decreased service or offline -- [TenantStatus](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-tenantstatus) +- [TenantStatus](#tenantstatus) ## KESConfig @@ -292,7 +292,7 @@ Service](https://github.com/minio/kes) (KES) StatefulSet deployed as part of the MinIO Tenant. KES supports Server-Side Encryption of objects using an external Key Management Service (KMS). -- [TenantSpec](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-tenantspec) +- [TenantSpec](#tenantspec)

domains TenantDomains

Optional
Specify a list of domains used to access MinIO and Console.

@@ -361,7 +361,7 @@ Operator console-secret.yaml for an example.

+href="#localcertificatereference">LocalCertificateReference

+href="#localcertificatereference">LocalCertificateReference

externalCertSecret LocalCertificateReference

Optional
Enables TLS with SNI support on each MinIO KES pod in the tenant. If externalCertSecret is omitted and @@ -386,7 +386,7 @@ on configuring TLS for MinIO Tenants.

clientCertSecret LocalCertificateReference

Optional
Specify a a Kubernetes @@ -526,9 +526,9 @@ LocalCertificateReference (`externalCertSecret`, containing TLS certificates or Certificate Authority files for use with enabling TLS in the MinIO Tenant. -- [KESConfig](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-kesconfig) +- [KESConfig](#kesconfig) -- [TenantSpec](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-tenantspec) +- [TenantSpec](#tenantspec) @@ -565,7 +565,7 @@ The type of Kubernetes secret. Specify Logging describes Logging for MinIO tenants. -- [TenantSpec](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-tenantspec) +- [TenantSpec](#tenantspec)
@@ -609,7 +609,7 @@ CRD](https://min.io/docs/minio/kubernetes/upstream/operations/install-deploy-man reference for the `pools` object for examples and more complete documentation. -- [TenantSpec](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-tenantspec) +- [TenantSpec](#tenantspec)
@@ -782,13 +782,13 @@ href="https://kubernetes.io/docs/concepts/containers/runtime-class/">https://kub PoolState represents the state of a pool -- [PoolStatus](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-poolstatus) +- [PoolStatus](#poolstatus) ## PoolStatus PoolStatus keeps track of all the pools and their current state -- [TenantStatus](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-tenantstatus) +- [TenantStatus](#tenantstatus)
@@ -810,7 +810,7 @@ PoolStatus keeps track of all the pools and their current state +href="#poolstate">PoolState

@@ -831,7 +831,7 @@ ServiceMetadata (`serviceMetadata`) defines custom labels and annotations for the MinIO Object Storage service and/or MinIO Console service. -- [TenantSpec](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-tenantspec) +- [TenantSpec](#tenantspec)

state PoolState

@@ -881,7 +881,7 @@ If provided, append these annotations to the Console service

SideCars (`sidecars`) defines a list of containers that the Operator attaches to each MinIO server pods in the `pool`. -- [TenantSpec](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-tenantspec) +- [TenantSpec](#tenantspec)
@@ -945,7 +945,7 @@ Tenant is a [Kubernetes object](https://kubernetes.io/docs/concepts/overview/working-with-objects/kubernetes-objects/) describing a MinIO Tenant. -- [TenantList](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-tenantlist) +- [TenantList](#tenantlist)
@@ -980,13 +980,13 @@ for fields of metadata.

+href="#tenantscheduler">TenantScheduler

+href="#tenantspec">TenantSpec

@@ -1001,7 +1001,7 @@ the domains listed, but external DNS configuration is still needed. The listed domains should include schema and port if any is used, i.e. -- [Features](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-features) +- [Features](#features)

scheduler TenantScheduler

spec TenantSpec

Required
The root field for the MinIO Tenant object.

@@ -1039,7 +1039,7 @@ href="https://console.domain.com:8123/subpath/">https://console.domain.com:8123/ TenantScheduler (`scheduler`) - Object describing Kubernetes Scheduler to use for deploying the MinIO Tenant. -- [Tenant](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-tenant) +- [Tenant](#tenant)
@@ -1074,7 +1074,7 @@ For more complete documentation on this object, see the [MinIO Kubernetes Documentation](https://min.io/docs/minio/kubernetes/upstream/operations/installation.html). -- [Tenant](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-tenant) +- [Tenant](#tenant)
@@ -1091,7 +1091,7 @@ Documentation](https://min.io/docs/minio/kubernetes/upstream/operations/installa +href="#localcertificatereference">LocalCertificateReference

+href="#features">Features

@@ -1337,7 +1337,7 @@ enabled such as bucketDNS etc.

+href="#certificateconfig">CertificateConfig

+href="#kesconfig">KESConfig

+href="#sidecars">SideCars

@@ -1413,7 +1413,7 @@ in the tenant.

+href="#exposeservices">ExposeServices

@@ -1422,7 +1422,7 @@ Directs the Operator to expose the MinIO and/or Console services.
+href="#servicemetadata">ServiceMetadata

@@ -1454,7 +1454,7 @@ starts.
+href="#logging">Logging

@@ -1516,7 +1516,7 @@ this rule, k8s will show the result.

TenantUsage are metrics regarding the usage and capacity of the tenant -- [TenantStatus](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-tenantstatus) +- [TenantStatus](#tenantstatus)

pools Pool +href="#pool">Pool array

Required
An array of objects describing each MinIO server pool deployed in the @@ -1161,7 +1161,7 @@ when deploying the Tenant resource.

externalCertSecret LocalCertificateReference +href="#localcertificatereference">LocalCertificateReference array

Optional
Enables TLS with SNI support on each MinIO pod in the tenant. If @@ -1188,7 +1188,7 @@ on configuring TLS for MinIO Tenants.

externalCaCertSecret LocalCertificateReference +href="#localcertificatereference">LocalCertificateReference array

Optional
Allows MinIO server pods to verify client TLS certificates signed by a @@ -1211,7 +1211,7 @@ on configuring TLS for MinIO Tenants.

externalClientCertSecret LocalCertificateReference

Optional
Enables mTLS authentication between the MinIO Tenant pods and MinIO KES. @@ -1231,7 +1231,7 @@ href="https://github.com/minio/kes/wiki/Configuration#policy-configuration">KES Wiki for more information on KES identities.
If deploying KES with the MinIO Operator, include the hash of the certificate as part of the kes +href="#kesconfig">kes object specification.
See the MinIO @@ -1242,7 +1242,7 @@ on configuring TLS for MinIO Tenants.

externalClientCertSecrets LocalCertificateReference +href="#localcertificatereference">LocalCertificateReference array

Optional
Provide support for mounting additional client certificate into MinIO @@ -1329,7 +1329,7 @@ it.

features Features

S3 related features can be disabled or enabled such as bucketDNS etc.

certConfig CertificateConfig

Optional
Enables setting the CommonName, Organization, and dnsName attributes for all TLS certificates @@ -1348,7 +1348,7 @@ effect if requestAutoCert is false.

kes KESConfig

Optional
Directs the MinIO Operator to deploy the MinIO Key Encryption Service @@ -1404,7 +1404,7 @@ href="https://kubernetes.io/docs/concepts/containers/images#updating-images">htt

sideCars SideCars

Optional
A list of containers to run as sidecars along every MinIO Pod deployed in the tenant.

exposeServices ExposeServices

Optional
Directs the Operator to expose the MinIO and/or Console services.

serviceMetadata ServiceMetadata

Optional
Specify custom labels and annotations to append to the MinIO service and/or Console service.

buckets Bucket +href="#bucket">Bucket array

Optional
Create buckets when creating a new tenant. Skip if bucket with given @@ -1463,7 +1463,7 @@ name already exists

logging Logging

Optional
Enable JSON, Anonymous logging for MinIO tenants.

@@ -1558,7 +1558,7 @@ bytes.

@@ -1570,7 +1570,7 @@ tiers in the tenant

TierUsage represents the usage from a tier setup by the tenant -- [TenantUsage](#k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-tenantusage) +- [TenantUsage](#tenantusage)

tiers TierUsage +href="#tierusage">TierUsage array

Tiers includes the usage of individual tiers in the tenant

diff --git a/sync-minio-operator-crd.sh b/sync-minio-operator-crd.sh index a0737060..ee03a4c0 100755 --- a/sync-minio-operator-crd.sh +++ b/sync-minio-operator-crd.sh @@ -14,10 +14,12 @@ function main() { "Darwin") sed -i '' 's%# API Reference%%g' source/includes/k8s/ext-tenant-crd.md sed -i '' 's%minio.min.io/v2%Operator CRD v2 Reference%g' source/includes/k8s/ext-tenant-crd.md + sed -i '' 's%k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-%%g' source/includes/k8s/ext-tenant-crd.md sed -i '' 's%# % %g' source/includes/k8s/ext-tenant-crd.md;; *) sed -i 's%# API Reference%%g' source/includes/k8s/ext-tenant-crd.md sed -i 's%minio.min.io/v2%Operator CRD v2 Reference%g' source/includes/k8s/ext-tenant-crd.md + sed -i 's%k8s-api-github-com-minio-operator-pkg-apis-minio-min-io-v2-%%g' source/includes/k8s/ext-tenant-crd.md sed -i 's%# % %g' source/includes/k8s/ext-tenant-crd.md;; esac } From 3858fa4d45b8c555e9daf28ac4cee641d6e3c8c1 Mon Sep 17 00:00:00 2001 From: Ravind Kumar Date: Tue, 10 Oct 2023 16:40:59 -0400 Subject: [PATCH 4/4] Updating Readme --- README.md | 23 ++++++++++++++++++++++- 1 file changed, 22 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 90c7bb10..42aa5e36 100644 --- a/README.md +++ b/README.md @@ -9,7 +9,7 @@ MinIO uses [Sphinx](https://www.sphinx-doc.org/en/master/index.html) to generate - Any GNU/Linux Operating System, or macOS 12.3 or later. - python 3.10.x and python-pip - python3.10-venv -- sphinx 4.3.2 +- sphinx 6.2.1 - nodejs 14.5.0 or later - npm 16.19.1 or later - `git` or a git-compatible client @@ -69,6 +69,27 @@ Does the following: 1. Check that the `build/GITDIR/linux` folder exists 2. Copies the contents of `build/GITDIR/linux/html/*` to `docs-staging/staging/GITDIR/linux` +# Syncing Operator CRD Docs + +For importing the Operator CRD Docs specifically, you must have: + +- pandoc (latest stable) +- asciidoc (latest stable) + +In addition to all other prerequisites. + +Run + +``` +make sync-operator-crd +``` + +This downloads and converts the `tenant-crd.adoc` from the MinIO Operator github repository. +It converts it to XML, then to markdown. +Finally, it does some `sed` find/replace to tidy up the file for Sphinx ingest. + +You can run this when we have a new Operator release being documented, assuming there are changes to the CRD as part of that release. + # License This project is licensed under a [Creative Commons Attribution 4.0 International License](https://creativecommons.org/licenses/by/4.0/legalcode). See [CONTRIBUTING.md](https://github.com/minio/docs/tree/master/CONTRIBUTING.md) guide for more information on contributing to the MinIO Documentation project.