Skip to content

Commit

Permalink
Add tls auth doc for rabbitmq scaler (kedacore#967) (kedacore#1036)
Browse files Browse the repository at this point in the history
* Add tls auth doc for rabbitmq scaler (kedacore#967)

Signed-off-by: Abhishek Mohite <[email protected]>

* Update content/docs/2.10/scalers/rabbitmq-queue.md

Co-authored-by: Jorge Turrado Ferrero <[email protected]>
Signed-off-by: Abhishek Mohite <[email protected]>

Signed-off-by: Abhishek Mohite <[email protected]>
Signed-off-by: Abhishek Mohite <[email protected]>
Co-authored-by: Jorge Turrado Ferrero <[email protected]>
  • Loading branch information
mohite-abhi and JorTurFer authored Jan 17, 2023
1 parent 752a362 commit 2e57a50
Showing 1 changed file with 66 additions and 0 deletions.
66 changes: 66 additions & 0 deletions content/docs/2.10/scalers/rabbitmq-queue.md
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,15 @@ TriggerAuthentication CRD is used to connect and authenticate to RabbitMQ:

> See the [RabbitMQ Ports](https://www.rabbitmq.com/networking.html#ports) section for more details on how to configure the ports.

**TLS authentication:**

- `tls` - To enable SSL auth for RabbitMQ, set this to `enable`. If not set, TLS for RabbitMQ is not used. (Values: `enable`, `disable`, Default: `disable`, Optional)
- `ca` - Certificate authority file for TLS client authentication. (Optional)
- `cert` - Certificate for client authentication. (Optional)
- `key` - Key for client authentication. (Optional)

> Using RabbitMQ host with amqps will require enabling the tls settings and passing the required parameters.

### Example

#### AMQP protocol:
Expand Down Expand Up @@ -111,6 +120,63 @@ spec:
name: keda-trigger-auth-rabbitmq-conn
```
#### AMQPS protocol with TLS auth:
```yaml
apiVersion: v1
kind: Secret
metadata:
name: keda-rabbitmq-secret
data:
host: <AMQPS URI connection string> # base64 encoded value of format amqps://guest:password@localhost:5672/vhost
tls: "enable"
ca: <your ca>
cert: <your cert>
key: <your key>
---
apiVersion: keda.sh/v1alpha1
kind: TriggerAuthentication
metadata:
name: keda-trigger-auth-rabbitmq-conn
namespace: default
spec:
secretTargetRef:
- parameter: host
name: keda-rabbitmq-secret
key: host
- parameter: tls
name: keda-rabbitmq-secret
key: tls
- parameter: ca
name: keda-rabbitmq-secret
key: ca
- parameter: cert
name: keda-rabbitmq-secret
key: cert
- parameter: key
name: keda-rabbitmq-secret
key: key
---
apiVersion: keda.sh/v1alpha1
kind: ScaledObject
metadata:
name: rabbitmq-scaledobject
namespace: default
spec:
scaleTargetRef:
name: rabbitmq-deployment
triggers:
- type: rabbitmq
metadata:
protocol: amqp
queueName: testqueue
mode: QueueLength
value: "20"
metricName: custom-testqueue #optional. Generated value would be `rabbitmq-custom-testqueue`
authenticationRef:
name: keda-trigger-auth-rabbitmq-conn
```
#### HTTP protocol (`QueueLength`):

```yaml
Expand Down

0 comments on commit 2e57a50

Please sign in to comment.