{"id":15056737,"url":"https://github.com/k8ssandra/cass-operator","last_synced_at":"2025-04-14T08:54:14.670Z","repository":{"id":37449291,"uuid":"352985724","full_name":"k8ssandra/cass-operator","owner":"k8ssandra","description":"The DataStax Kubernetes Operator for Apache Cassandra","archived":false,"fork":false,"pushed_at":"2025-03-21T09:40:03.000Z","size":3881,"stargazers_count":196,"open_issues_count":77,"forks_count":68,"subscribers_count":11,"default_branch":"master","last_synced_at":"2025-04-07T01:09:47.235Z","etag":null,"topics":["cassandra","k8ssandra","kubernetes","operator"],"latest_commit_sha":null,"homepage":"https://docs.datastax.com/en/cass-operator/doc/cass-operator/cassOperatorGettingStarted.html","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/k8ssandra.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":".github/CODEOWNERS","security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2021-03-30T12:02:09.000Z","updated_at":"2025-04-04T20:31:12.000Z","dependencies_parsed_at":"2023-09-26T17:10:48.972Z","dependency_job_id":"4f3de4ba-3626-454d-bc8d-1c3a6d6ed2c1","html_url":"https://github.com/k8ssandra/cass-operator","commit_stats":{"total_commits":728,"total_committers":52,"mean_commits":14.0,"dds":0.7733516483516484,"last_synced_commit":"3b43dfe0c394ef7ee1a2c3b7d7fdf3157c2afcf7"},"previous_names":[],"tags_count":45,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/k8ssandra%2Fcass-operator","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/k8ssandra%2Fcass-operator/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/k8ssandra%2Fcass-operator/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/k8ssandra%2Fcass-operator/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/k8ssandra","download_url":"https://codeload.github.com/k8ssandra/cass-operator/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248852109,"owners_count":21171839,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cassandra","k8ssandra","kubernetes","operator"],"created_at":"2024-09-24T21:55:58.381Z","updated_at":"2025-04-14T08:54:14.644Z","avatar_url":"https://github.com/k8ssandra.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Cass Operator\n[![License: Apache License 2.0](https://img.shields.io/github/license/k8ssandra/cass-operator)](https://github.com/k8ssandra/cass-operator/blob/master/LICENSE.txt)\n\nThe DataStax Kubernetes Operator for Apache Cassandra\u0026reg;. This repository replaces the old [datastax/cass-operator](https://github.com/datastax/cass-operator) for use-cases in the k8ssandra project. Some documentation is still out of date and will be modified in the future. Check [k8ssandra/k8ssandra](https://github.com/k8ssandra/k8ssandra) for more up to date information.\n\n## Getting Started\n\n``cass-operator`` can be used as standalone product to manage your Cassandra cluster or as part of the (https://docs.k8ssandra.io/install/)[k8ssandra-operator]. With tooling such as managed repairs and automated backups, see k8ssandra-operator as the recommended approach. \n\nIf updating from previous versions, please see ``Upgrade instructions`` section first.\n\n### Installing the operator with Helm\n\ncass-operator is available as a Helm chart as part of the k8ssandra project. First add the k8ssandra Helm repository:\n\n```console\nhelm repo add k8ssandra https://helm.k8ssandra.io/stable\nhelm repo update\n```\n\nThen to install the cass-operator using the default settings to namespace ``cass-operator``, use the following command:\n\n```console\nhelm install cass-operator k8ssandra/cass-operator -n cass-operator --create-namespace\n```\n\nYou can modify the installation using the values from our (values.yaml)[https://github.com/k8ssandra/k8ssandra/blob/main/charts/cass-operator/values.yaml] file.\n\nBy default, the Helm installation requires ``cert-manager`` to be present in the Kubernetes installation. If you do not have cert-manager installed, follow the steps at (https://cert-manager.io/docs/installation/helm/)[cert-manager's] documentation. If you do not wish to use cert-manager, either disable the webhooks using ``--set admissionWebhooks.enabled=false`` or provide your own certificate in a secret and set it with ``--set admissionWebhooks.customCertificate=namespace/certificate-name``. \n\n### Installing the operator with Kustomize\n\nThe operator can be installed in a namespace scoped settings or cluster wide. If installed cluster wide, one can define which namespaces (or all) are watched for ``CassandraDatacenter`` objects.\n\nDefault installation is simple, the kubectl will create a namespace ``cass-operator`` and install cass-operator there. It will only listen for the CassandraDatacenters in that namespace. Note that since the manifests will install a [Custom Resource Definition](https://kubernetes.io/docs/concepts/extend-kubernetes/api-extension/custom-resources/), the user running the commands will need cluster-admin privileges.\n\nDefault install requires cert-manager to be installed, since webhooks require TLS certificates to be injected. See below how to install cert-manager if your environment does not have it installed previously.\n\n```console\nkubectl apply --force-conflicts --server-side -k github.com/k8ssandra/cass-operator/config/deployments/default?ref=v1.23.2\n```\n\nIf you wish to install it with cluster wide rights to monitor all the namespaces for ``CassandraDatacenter`` objects, use the following command:\n\n```console\nkubectl apply --force-conflicts --server-side -k github.com/k8ssandra/cass-operator/config/deployments/cluster?ref=v1.23.2\n```\n\nAlternatively, if you checkout the code, you can use ``make deploy`` to run [Kustomize](https://kustomize.io/) and deploy the files.\n\nThis will deploy the operator, along with any requisite resources such as Role, RoleBinding, etc., to the `cass-operator` namespace. You can check to see if the operator is ready as follows:\n\n```console\n$ kubectl -n cass-operator get pods --selector name=cass-operator\nNAME                             READY   STATUS    RESTARTS   AGE\ncass-operator-555577b9f8-zgx6j   1/1     Running   0          25h\n```\n\n#### Install Prometheus monitor rules\n\nIf you have Prometheus installed in your cluster, you can apply the following command to install the Prometheus support:\n\n```console\nkubectl apply -k github.com/k8ssandra/cass-operator/config/prometheus?ref=v1.23.2\n```\n\n#### Install cert-manager\n\nWe have tested the current cass-operator to work with cert-manager versions 1.12.2. Other versions should work also. To install 1.12.2 to your cluster, run the following command:\n\n```console\nkubectl apply -f https://github.com/cert-manager/cert-manager/releases/download/v1.12.2/cert-manager.yaml\n```\n\n#### Modifying the Kustomize template\n\nIf you wish to modify the deployment, create your own ``kustomization.yaml`` and modify it to your needs. The starting point could be the ``deployments/config/default`` and we'll add a cluster scoped installation as our component:\n\n```yaml\napiVersion: kustomize.config.k8s.io/v1beta1\nkind: Kustomization\n\nnamespace: cass-operator\n\nresources:\n  - github.com/k8ssandra/cass-operator/config/deployments/default?ref=v1.23.2\n\ncomponents:\n  - github.com/k8ssandra/cass-operator/config/components/cluster?ref=v1.23.2\n```\n\nWe provide both components to modify the installation as well as some additional resources for custom features. At the moment, you can modify the behavior of the installation in the following ways, or remove a component to\nignore the feature (components enabled in the default installation are marked with asterisk). Apply ``github.com/k8ssandra/cass-operator/config/components/`` before component name if using remote installation:\n\n| Component name | Description |\n| ------------- | ------------- |\n| namespace | Create namespace before installation* |\n| webhook | Enable validation webhooks in cass-operator (requires cert-manager) * |\n| clusterscope | Install cass-operator in a cluster scope, monitoring all the namespaces |\n\nAnd following resource. Apply ``github.com/k8ssandra/cass-operator/config/`` before resource name if using remote installation:\n\n| Resource | Description |\n| ------------- | ------------- |\n| prometheus | Add metrics scraping for Prometheus |\n\nYou can find more resources on how Kustomize works from their [documentation](https://kubectl.docs.kubernetes.io/installation/kustomize/). You can install kustomize with ``make kustomize`` if you do not have it already (this will install it to ``bin/kustomize``).\n\n##### Using kustomize to modify the default registry that's used by cass-operator\n\ncass-operator's default image name patterns and repositories are defined in a [image_config.yaml](https://github.com/k8ssandra/cass-operator/blob/master/config/manager/image_config.yaml) file. The image_config.yaml will define only the deployed Cassandra / DSE and server-system-logger images, not the cass-operator itself. To modify imageConfig when deploying, we can create a kustomize component to replace this file in the deployment with our own.\n\nIn this example, create two directories, ``our_installation`` and ``private_config_component``. You can name these as you wish, just remember to replace the directory names in the yaml files.\n\nIn ``private_config_component`` create two files, ``kustomization.yaml`` and ``image_config.yaml``. Lets say our registry is located at ``localhost:5000``, here's the ``private_config_component/image_config.yaml``:\n\n```yaml\napiVersion: config.k8ssandra.io/v1beta1\nkind: ImageConfig\nmetadata:\n  name: image-config\nimages:\n  system-logger: \"k8ssandra/system-logger:v1.23.2\"\n  config-builder: \"datastax/cass-config-builder:1.0-ubi7\"\n  imageRegistry: \"localhost:5000\"\ndefaults:\n  cassandra:\n    repository: \"k8ssandra/cass-management-api\"\n  dse:\n    repository: \"datastax/dse-server\"\n    suffix: \"-ubi7\"\n```\n\nAnd for ``private_config_component/kustomization.yaml`` you will need the following:\n\n```yaml\napiVersion: kustomize.config.k8s.io/v1alpha1\nkind: Component\n\nconfigMapGenerator:\n- files:\n  - image_config.yaml\n  behavior: merge\n  name: manager-config\n```\n\nFinally, the kustomization file which we'll deploy will look this (add cluster component if you wish to deploy in cluster-scope), add to ``our_installation/kustomization.yaml``:\n\n```yaml\napiVersion: kustomize.config.k8s.io/v1beta1\nkind: Kustomization\n\nresources:\n  - github.com/k8ssandra/cass-operator/config/deployments/default?ref=v1.23.2\n\ncomponents:\n  - components/private_image_config\n```\n\nIf you also wish to load the cass-operator from a different path, you will need to add the following part to the ``our_installation/kustomization.yaml``:\n\n```yaml\nimages:\n- name: controller\n  newName: localhost:5000/k8ssandra/cass-operator\n  newTag: v1.23.2\n```\n\nRun ``kubectl apply -k our_installation`` to install cass-operator.\n\n### Installing the operator with Operator Lifecycle Manager (or installing to Openshift)\n\ncass-operator is available in the OperatorHub as a community version as well as certified version. You can install these directly from the Openshift's UI.\n\nFor other distributions of Kubernetes, you can find cass-operator from the OperatorHub under the name (https://operatorhub.io/operator/cass-operator-community)[cass-operator-community].\n\nIf OLM is already installed in your cluster, the operator can be installed with the following command:\n\n```\nkubectl create -f https://operatorhub.io/install/cass-operator-community.yaml\n```\n\n### Upgrade instructions:\n\nUpdates are supported from previous versions of ``k8ssandra/cass-operator``. If upgrading from versions older than 1.7.0 (released under ``datastax/cass-operator`` name), please upgrade first to version 1.7.1. The following instructions apply when upgrading from 1.7.1 to 1.8.0 or newer up to 1.10.1. Upgrading to 1.11.0 if using Kubernetes 1.23 requires updating at least to 1.8.0 first, since 1.7.1 can not be used in Kubernetes 1.23 or newer.\n\nIf you're upgrading from 1.7.1, there is an additional step to take due to the modifications to cass-operator’s underlying controller-runtime and updated Kubernetes versions. These steps need to be done manually before updating to the newest version of cass-operator. Newer Kubernetes versions require stricter validation and as such we need to remove ``preserveUnknownFields`` global property from the CRD to allow us to update to a newer CRD. The newer controller-runtime on the other hand modifies the liveness, readiness and configuration options, which require us to delete the older deployment. These commands do not delete your running Cassandra instances.\n\n Run the following commands assuming cass-operator is installed to ``cass-operator`` namespace (change -n parameter if it is installed to some other namespace):\n\n```sh\nkubectl -n cass-operator delete deployment.apps/cass-operator\nkubectl -n cass-operator delete service/cassandradatacenter-webhook-service\nkubectl patch crd cassandradatacenters.cassandra.datastax.com -p '{\"spec\":{\"preserveUnknownFields\":false}}'\n```\n\nYou can now install new version of cass-operator as instructed previously.\n\n\n## Supported versions\n\nWe actively maintain two different versions of cass-operator, the [1.10.x series](https://github.com/k8ssandra/cass-operator/tree/1.10.x) as well as the newest version cut from the master branch. The [1.10.x branch](https://github.com/k8ssandra/cass-operator/tree/1.10.x) receives only bugfixes, while all the new features will only land to the newer versions.\n\n### Kubernetes and Openshift version support\n\n1.10.x versions support Kubernetes versions 1.18 to 1.25. For Openshift, 1.10.x supports 4.7 and 4.8 (it will not pass validations in 4.9 due to the use of deprecated APIs).\n\nNewer releases (1.11.0 and up) are tested and supported only in supported Kubernetes versions. That means versions 1.21 and up. For Openshift installations, 1.11.0 and up are supported in 4.9 and newer.\n\n### Cassandra version support\n\nFor Cassandra versions, 1.10.x will only support 3.11.x and 4.0.x. For 4.1 and 5.0, we recommend using a build 1.17.0 or newer. Support for 4.1 will only land in upcoming versions (1.13.0 or later). Both versions support all DSE 6.8.x releases.\n\n## Changelog between versions\n\nThe next major/minor version always includes changes from the previously released supported version, but no more than that. That is, if the patch release is released after the next (next in semver) major/minor, the patches are not integrated to it, but are repeated in the changelog for the next version if required (in some cases the bugfixes are not necessary for the next major/minor).\n\nAs an example, lets say the changelog has the following release sequence:\n\n```\n1.12.0\n1.10.5\n1.11.0\n1.10.4\n..\n1.10.0\n```\n\n1.11.0 will include everything under it, including fixes from 1.10.4, however 1.11.0 does not have the fixes from 1.10.5 (as 1.11.0 was released before 1.10.5). 1.12.0 on the other hand will include all the fixes from 1.10.5, but those fixes are repeated as 1.12.0 lists everything changed from the previous major/minor, that is changes between 1.11.0 and 1.12.0.\n\nWhile the 1.10.x branch will only have fixes released from that branch, the master branch will include all the versions.\n\n## Creating a Cassandra cluster\n\n### Creating a storage class\n\nIf the ``default`` StorageClass is not suitable for use (volumeBindingMode WaitForFirstConsumer is required) or you wish to use different one, you will need to create an appropriate storage class which will define the type of storage to use for Cassandra nodes in a cluster. For example, here is a storage class for using SSDs in GKE:\n\n```yaml\napiVersion: storage.k8s.io/v1\nkind: StorageClass\nmetadata:\n  name: server-storage\nprovisioner: kubernetes.io/gce-pd\nparameters:\n  type: pd-ssd\n  replication-type: none\nvolumeBindingMode: WaitForFirstConsumer\nreclaimPolicy: Delete\n```\n\nPaste the above to a file and apply:\n\n```\nkubectl apply -f https://raw.githubusercontent.com/k8ssandra/cass-operator/v1.23.2/operator/k8s-flavors/gke/storage.yaml\n```\n\n### Creating a CassandraDatacenter\n\nThe following resource defines a Cassandra 4.0.1 datacenter with 3 nodes on one rack, which you can also find at [config/samples/example-cassdc-three-nodes-single-rack.yaml](config/samples/example-cassdc-three-nodes-single-rack.yaml):\n\n```yaml\napiVersion: cassandra.datastax.com/v1beta1\nkind: CassandraDatacenter\nmetadata:\n  name: dc1\nspec:\n  clusterName: development\n  serverType: cassandra\n  serverVersion: \"4.0.1\"\n  managementApiAuth:\n    insecure: {}\n  size: 3\n  storageConfig:\n      cassandraDataVolumeClaimSpec:\n        storageClassName: server-storage\n        accessModes:\n          - ReadWriteOnce\n        resources:\n          requests:\n            storage: 10Gi\n  resources:\n    requests:\n      memory: 2Gi\n      cpu: 1000m\n  podTemplateSpec:\n    securityContext: {}\n    containers:\n      - name: cassandra\n        securityContext: {}\n  racks:\n    - name: rack1\n  config:\n    jvm-server-options:\n      initial_heap_size: \"1G\"\n      max_heap_size: \"1G\"\n    cassandra-yaml:\n      num_tokens: 16\n      authenticator: PasswordAuthenticator\n      authorizer: CassandraAuthorizer\n      role_manager: CassandraRoleManager\n\n```\n\nApply the above as follows:\n\n```console\nkubectl -n cass-operator apply -f https://raw.githubusercontent.com/k8ssandra/cass-operator/master/config/samples/example-cassdc-three-nodes-single-rack.yaml\n```\n\nYou can check the status of pods in the Cassandra cluster as follows:\n\n```console\n$ kubectl -n cass-operator get pods --selector cassandra.datastax.com/cluster=cluster1\nNAME                         READY   STATUS    RESTARTS   AGE\ncluster1-dc1-default-sts-0   2/2     Running   0          26h\ncluster1-dc1-default-sts-1   2/2     Running   0          26h\ncluster1-dc1-default-sts-2   2/2     Running   0          26h\n```\n\nYou can check to see the current progress of bringing the Cassandra datacenter online by checking the `cassandraOperatorProgress` field of the `CassandraDatacenter`'s `status` sub-resource as follows:\n\n```console\n$ kubectl -n cass-operator get cassdc/dc1 -o \"jsonpath={.status.cassandraOperatorProgress}\"\nReady\n```\n\n(`cassdc` and `cassdcs` are supported short forms of `CassandraDatacenter`.)\n\nA value of \"Ready\", as above, means the operator has finished setting up the Cassandra datacenter.\n\nYou can also check the Cassandra cluster status using `nodetool` by invoking it on one of the pods in the Cluster as follows:\n\n```console\n$ kubectl -n cass-operator exec -it -c cassandra cluster1-dc1-default-sts-0 -- nodetool status\nDatacenter: dc1\n===============\nStatus=Up/Down\n|/ State=Normal/Leaving/Joining/Moving/Stopped\n--  Address         Load       Tokens       Owns (effective)  Host ID                               Rack\nUN  10.233.105.125  224.82 KiB  1            65.4%             5e29b4c9-aa69-4d53-97f9-a3e26115e625  r1\nUN  10.233.92.96    186.48 KiB  1            61.6%             b119eae5-2ff4-4b06-b20b-c492474e59a6  r1\nUN  10.233.90.54    205.1 KiB   1            73.1%             0a96e814-dcf6-48b9-a2ca-663686c8a495  r1\n```\n\nThe operator creates a secure Cassandra cluster by default, with a new superuser (not the traditional `cassandra` user) and a random password. You can get those out of a Kubernetes secret and use them to log into your Cassandra cluster for the first time. For example:\n\n```console\n$ # get CASS_USER and CASS_PASS variables into the current shell\n$ CASS_USER=$(kubectl -n cass-operator get secret cluster1-superuser -o json | jq -r '.data.username' | base64 --decode)\n$ CASS_PASS=$(kubectl -n cass-operator get secret cluster1-superuser -o json | jq -r '.data.password' | base64 --decode)\n$ kubectl -n cass-operator exec -ti cluster1-dc1-default-sts-0 -c cassandra -- sh -c \"cqlsh -u '$CASS_USER' -p '$CASS_PASS'\"\n\nConnected to cluster1 at 127.0.0.1:9042.\n[cqlsh 5.0.1 | Cassandra 3.11.6 | CQL spec 3.4.4 | Native protocol v4]\nUse HELP for help.\n\ncluster1-superuser@cqlsh\u003e select * from system.peers;\n\n peer      | data_center | host_id                              | preferred_ip | rack    | release_version | rpc_address | schema_version                       | tokens\n-----------+-------------+--------------------------------------+--------------+---------+-----------------+-------------+--------------------------------------+--------------------------\n 10.28.0.4 |         dc1 | 4bf5e110-6c19-440e-9d97-c013948f007c |         null | default |          3.11.6 |   10.28.0.4 | e84b6a60-24cf-30ca-9b58-452d92911703 | {'-7957039572378599263'}\n 10.28.5.5 |         dc1 | 3e84b0f1-9c1e-4deb-b6f8-043731eaead4 |         null | default |          3.11.6 |   10.28.5.5 | e84b6a60-24cf-30ca-9b58-452d92911703 | {'-3984092431318102676'}\n\n(2 rows)\n```\n\n## Features\n\n- Proper token ring initialization, with only one node bootstrapping at a time\n- Seed node management - one per rack, or three per datacenter, whichever is more\n- Server configuration integrated into the CassandraDatacenter CRD\n- Rolling reboot nodes by changing the CRD\n- Store data in a rack-safe way - one replica per cloud AZ\n- Scale up racks evenly with new nodes\n- Scale down racks evenly by decommissioning existing nodes\n- Replace dead/unrecoverable nodes\n- Multi DC clusters (limited to one Kubernetes namespace)\n\nAll features are documented in the [User Documentation](docs/user/README.md).\n\n### Containers\n\nThe operator is comprised of the following container images working in concert:\n\n* The operator, built from sources using the kubebuilder v3 structure, from [controllers](controllers/) directory.\n* The config builder init container, built from sources in [datastax/cass-config-builder](https://github.com/datastax/cass-config-builder).\n* For Cassandra 4.1 and up, we use [k8ssandra-client](https://github.com/k8ssandra/k8ssandra-client) to build the configuration.\n* server-system-logger, a Vector agent for outputting Cassandra logs for kubectl. Implemented in [logger.Dockerfile](logger.Dockerfile)\n* Cassandra/DSE, built from [datastax/management-api-for-apache-cassandra](https://github.com/k8ssandra/management-api-for-apache-cassandra),\n\nThe Cassandra container must be built with support for management-api, otherwise cass-operator will fail to work correctly.\n\n### Overriding properties of cass-operator created containers\n\nIf the CassandraDatacenter specifies a podTemplateSpec field, then containers with specific names can be used to override default settings in containers that will be created by cass-operator.\n\nCurrently cass-operator will create an init container with the name of \"server-config-init\". Containers that will be created have the names \"cassandra\" and \"server-system-logger\".\n\nIn general, the values specified in this way by the user will override anything generated by cass-operator.\n\nOf special note is that user-specified environment variables, ports, and volumes in the corresponding containers will be added to the values that cass-operator automatically generates for those containers.\n\n```yaml\napiVersion: cassandra.datastax.com/v1beta1\nkind: CassandraDatacenter\nmetadata:\n  name: dc1\nspec:\n  clusterName: cluster1\n  serverType: cassandra\n  serverVersion: 3.11.11\n  managementApiAuth:\n    insecure: {}\n  size: 3\n  podTemplateSpec:\n    spec:\n      initContainers:\n        - name: \"server-config-init\"\n          env:\n          - name: \"EXTRA_PARAM\"\n            value: \"123\"\n      containers:\n        - name: \"cassandra\"\n          terminationMessagePath: \"/dev/other-termination-log\"\n          terminationMessagePolicy: \"File\"\n  storageConfig:\n    cassandraDataVolumeClaimSpec:\n      storageClassName: server-storage\n      accessModes:\n      - ReadWriteOnce\n      resources:\n        requests:\n          storage: 5Gi\n  config:\n    cassandra-yaml:\n      authenticator: org.apache.cassandra.auth.PasswordAuthenticator\n      authorizer: org.apache.cassandra.auth.CassandraAuthorizer\n      role_manager: org.apache.cassandra.auth.CassandraRoleManager\n    jvm-options:\n      initial_heap_size: 800M\n      max_heap_size: 800M\n```\n\n## Requirements\n\n- Kubernetes cluster, 1.21 or newer. For Openshift, version 4.9 or newer. If you're using older versions, please install from [1.10.x branch](https://github.com/k8ssandra/cass-operator/tree/1.10.x), which supports Openshift 4.7 and Kubernetes 1.19.\n\n## Contributing\n\nIf you wish to file a bug, enhancement proposal or have other questions, use the issues in this repository. We also accept PRs from the community.\n\nFor other means of contacting, check [k8ssandra community](https://k8ssandra.io/community/) resources.\n\n### Developer setup\n\nAlmost every build, test, or development task requires the following pre-requisites...\n\n* Golang 1.21 or newer\n* Docker, either the docker.io packages on Ubuntu, Docker Desktop for Mac,\n  or your preferred docker distribution. Other container engines such as podman should work also.\n* Kind or similar Kubernetes distribution for testing (Docker Desktop / Minikube will work if correct StorageClass is added)\n\n### Building\n\nThe operator uses Makefiles for its build process.\n\n#### Build the Operator Container Image\nThis build task will create the operator container image, building or rebuilding the binary from golang sources if necessary:\n\n``` bash\nmake docker-build\n```\n\n#### Build the Operator Binary\nIf you wish to perform ONLY to the golang build or rebuild, without creating\na container image:\n\n``` bash\nmake build\n```\n\nOr just ``make``.\n\n#### Build and deploy to kind\nTo simplify testing processes, the following command will build the docker image and load it to the kind instance.\n\n```bash\nmake docker-kind\n```\n\n### Testing\n\nTests are separated to unit-tests (including [envtests](https://book.kubebuilder.io/cronjob-tutorial/writing-tests.html)) and end-to-end tests. To run the unit tests and envtests, use:\n\n``` bash\nmake test\n```\n\ntest target will spawn a envtest environment, which will require the ports to be available. To test the unit test workflow, one can use the [act](https://github.com/nektos/act) to run the tests with simply running `act -j testing`. While integration tests will work with `act` also, we do not recommend that, since it runs them serially and that takes a long time.\n\n#### End-to-end Automated Testing\n\nRun fully automated end-to-end tests (these will take a while and require a Kubernetes cluster access with up to 6 worker nodes):\n\n```bash\nmake integ-test\n```\n\nTo run a single e2e test:\n\n```bash\nM_INTEG_DIR=test_dir make integ-test\n```\n\nMore details of end-to-end testing are [here](tests/README.md).\n\n## Uninstall\n\n*This will destroy all of your data!*\n\nDelete your CassandraDatacenters first, otherwise Kubernetes will block deletion of the namespace because we use a finalizer. The following command deletes all CassandraDatacenters from all namespaces:\n\n```\nkubectl delete cassdcs --all-namespaces --all\n```\n\nIf you used the ``make deploy`` to deploy the operator, replace it with ``make undeploy`` to uninstall. With the `kubectl apply -k` option, replace it with `kubectl delete -k`.\n\n## Contacts\n\nFor questions, please reach out on [k8ssandra Community](https://k8ssandra.io/community/) channels. For development questions, we are active on our Discord channel #k8ssandra-dev. Or you can open an issue.\n\n## License\n\nCopyright DataStax, Inc.\n\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use this file except in compliance with the License. You may obtain a copy of the License at\n\nhttp://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software distributed under the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fk8ssandra%2Fcass-operator","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fk8ssandra%2Fcass-operator","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fk8ssandra%2Fcass-operator/lists"}