rabbitmq / cluster-operator

RabbitMQ Cluster Kubernetes Operator
https://www.rabbitmq.com/kubernetes/operator/operator-overview.html
Mozilla Public License 2.0
884 stars 273 forks source link

Update condition to enable Web MQTT/STOMP TLS ports #1735

Closed Zerpet closed 1 month ago

Zerpet commented 1 month ago

This closes #1677

Note to reviewers: remember to look at the commits in this PR and consider if they can be squashed

Summary Of Changes

There was a condition that CA bundle secret name must be provided. This was encapsulated in the function MutualTLSEnabled(). After this commit, the only condition to enable Web MQTT/STOMP TLS ports is to have a secret name in the tls attribute of the spec.

Local Testing

Please ensure you run the unit, integration and system tests before approving the PR.

To run the unit and integration tests:

$ make unit-tests integration-tests

You will need to target a k8s cluster and have the operator deployed for running the system tests.

For example, for a Kubernetes context named dev-bunny:

$ kubectx dev-bunny
$ make destroy deploy-dev
# wait for operator to be deployed
$ make system-tests