Skip to content

Commit

Permalink
Merge pull request #2 from djones6/fix-sbr
Browse files Browse the repository at this point in the history
Update ServiceBindingRequests to work with latest Operator
  • Loading branch information
matthewpwilson authored Sep 9, 2020
2 parents a65b8d5 + 005b7c4 commit 15be06a
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 18 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,23 +3,18 @@ kind: ServiceBindingRequest
metadata:
name: barista-kafka
spec:
# applicationSelector isn't needed anymore once https://github.com/redhat-developer/service-binding-operator/issues/296 is implemented
applicationSelector:
group: apps
resource: deployments
resourceRef: barista-kafka
version: v1
# Service Binding Operator doesn't support binding across namespaces until https://github.com/redhat-developer/service-binding-operator/issues/314 is implemented.
# Assumption: Kafka and the application are deployed to the same namespace
backingServiceSelector:
group: kafka.strimzi.io
backingServiceSelectors:
- group: kafka.strimzi.io
kind: Kafka
resourceRef: my-cluster
version: v1beta1
id: mycluster
customEnvVar:
- name: KAFKA_BOOTSTRAP_SERVERS
value: |-
{{- range .status.listeners -}}
{{- range .mycluster.status.listeners -}}
{{- if eq .type "plain" -}}
{{ .bootstrapServers }}
{{- end -}}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,23 +3,18 @@ kind: ServiceBindingRequest
metadata:
name: coffeeshop-ui-kafka
spec:
# applicationSelector isn't needed anymore once https://github.com/redhat-developer/service-binding-operator/issues/296 is implemented
applicationSelector:
group: apps
resource: deployments
resourceRef: coffeeshop-ui
version: v1
# Service Binding Operator doesn't support binding across namespaces until https://github.com/redhat-developer/service-binding-operator/issues/314 is implemented.
# Assumption: Kafka and the application are deployed to the same namespace
backingServiceSelector:
group: kafka.strimzi.io
backingServiceSelectors:
- group: kafka.strimzi.io
kind: Kafka
resourceRef: my-cluster
version: v1beta1
id: mycluster
customEnvVar:
- name: MP_MESSAGING_CONNECTOR_LIBERTY_KAFKA_BOOTSTRAP_SERVERS
value: |-
{{- range .status.listeners -}}
{{- range .mycluster.status.listeners -}}
{{- if eq .type "plain" -}}
{{ .bootstrapServers }}
{{- end -}}
Expand Down

0 comments on commit 15be06a

Please sign in to comment.