Reputation: 4932
I'm trying to use azure's spring-cloud-azure-appconfiguration-config-web with spring-cloud-kubernetes-config. The idea is to define
in kubernetes configmap application-kubernetes.yaml
and also bootstrap-kubernetes.yaml
. Inside bootstrap-kubernetes.yaml
I'd like to define system variable which should be populated from kubernetes secrets.
kind: ConfigMap
apiVersion: v1
metadata:
name: {{ template "chart.fullname" . }}
data:
application-kubernetes.yaml: |-
...
bootstrap-kubernetes.yaml: |-
spring:
cloud:
azure:
appconfiguration:
stores:
- connection-string: ${APP_CONFIGURATION_CONNECTION_STRING}
Unfortunately with this setup it's not possible to run appconfig because it fails on error:
Caused by: java.lang.IllegalArgumentException: At least one config store has to be configured.
at org.springframework.util.Assert.notEmpty(Assert.java:467)
at com.microsoft.azure.spring.cloud.config.AppConfigurationProperties.validateAndInit(AppConfigurationProperties.java:123)
So the question is, is it possible to set up such configuration where the configmap will be retrieved first and then the appconfig will be configured by properties used in configmap?
Upvotes: 0
Views: 913
Reputation: 1533
This is the same issue discussed in App Configuration Github repo at:
https://github.com/Azure/AppConfiguration/issues/409.
Upvotes: 0