Search code examples
springkubernetes-helm

Second spring profile in java_options


I use Teamcity, Helm and Spring. i have param in TC java_opts =

-Dspring.profiles.active=feature,audit 
-Xmx%app.java.max_heap% ... 

in helm chart i have deployment.yaml with

           env:
            - name: JAVA_OPTS
              value: "{{ .Values.java_opts }}"

I expected spring to initialize the context with two profiles: feature and audit. But in log i see

2020-07-27 18:03:09.949 [main] [] INFO  r.t.b.priestback.PriestBackApplicationKt - The following profiles are active: feature

How add second profile?


Solution

  • it's bad parsing in Helm https://github.com/helm/helm/issues/1556 i change on

    -Dspring.profiles.active=feature\,audit