This page provides reference information for API resources related to Services and Service Bindings.
apiVersion: services.tanzu.vmware.com/v1
kind: ServiceBinding
metadata:
name: name-of-the-service-binding
spec:
# targetRef is the reference to the target resource that the service is being bound to.
targetRef:
apiGroup: apps.tanzu.vmware.com
kind: ContainerApp
name: name-of-containerapp
# serviceRef is the reference to the service that will be bound to the target workload.
serviceRef:
apiGroup: bitnami.database.tanzu.vmware.com
kind: PostgreSQLInstance
name: dev-postgres
# alias is an optional field that can be used to provide the directory name of the
# target volume mount that is going to contain the binding details. If not set, the directory
# name of the volume mount will be the ServiceBinding .metadata.name.
alias: devdb
apiVersion: services.tanzu.vmware.com/v1
kind: PreProvisionedService
metadata:
name: prod-aws-aurora-postgres
spec:
# Meta-information regarding the service
description: Aurora Global Database spanning us-east and eu-west
contact:
email: [email protected]
bindingConnectors:
- name: read-write
description: Read-write available in all availability targets
# type should conform to the "type" from Spring Cloud Bindings
type: mysql
# A different secret, conforming to the Kubernetes Service Binding spec should be provided for each AT in the Space.
availabilityTargets:
us-east:
secretRef:
name: secret-aurora-rw-us-east
eu-west:
secretRef:
name: secret-aurora-rw-eu-west
# The names of the bindingConnectors can be arbitrary
- name: read-only
description: Read-only available in all availability targets
type: mysql
# For use-cases in which the secret is the same for all ATs, this shorthand notation can be used.
secretRef:
name: secret-aurora-ro
apiVersion: bitnami.messaging.tanzu.vmware.com/v1alpha1
kind: KafkaInstance
metadata:
name: kafka
spec:
# Storage size in GB
storageGB: 1
---
apiVersion: bitnami.database.tanzu.vmware.com/v1alpha1
kind: MongoDBInstance
metadata:
name: mongo
spec:
storageGB: 1
---
apiVersion: bitnami.database.tanzu.vmware.com/v1alpha1
kind: MySQLInstance
metadata:
name: mysql
spec:
storageGB: 1
---
apiVersion: bitnami.database.tanzu.vmware.com/v1alpha1
kind: PostgreSQLInstance
metadata:
name: postgres
spec:
storageGB: 1
---
apiVersion: bitnami.messaging.tanzu.vmware.com/v1alpha1
kind: RabbitmqCluster
metadata:
name: rabbit
spec:
storageGB: 2
# Number of Pod replicas
replicas: 1
---
apiVersion: bitnami.caching.tanzu.vmware.com/v1alpha1
kind: RedisCluster
metadata:
name: redis
spec:
storageGB: 1