I have an SCDF task that reads information from a database and outputs messages to Kafka. For connecting to Kafka I have a private + public key pair stored in a PKCS12 keystore.
Usually, when I have a regular app running as a pod in Kubernetes, I mount the keystore as a file from a Kubernetes secret. I like to do the same for the SCDF task, but I can't figure out if this is at all possible.
The way to provide application configuration to the task is to add them as application properties, prefixed with the application name like this:
app.my-app-name.spring.kafka.bootstrap-servers=kafka-host:443
app.my-app-name.spring.kafka.security.protocol=SSL
app.my-app-name.spring.kafka.ssl.keystore.password=password
app.my-app-name.spring.kafka.ssl.key.password=password
For providing the keystore I need something else. Since I'm using K8s as a target to run the SCDF task, is it possible to inject configuration from config maps and secrets? I couldn't find any clear documentation or examples about this.
I overlooked this part in the documentation apparently.... It's all described in paragraphs 5.1.12 - 5.1.15, starting here https://docs.spring.io/spring-cloud-dataflow/docs/current/reference/htmlsingle/#_secret_references