Environment Variables for Maven Build (Spring Boot)

java
circle.yml

#1

Hey All!

I’m attempting to reference environment variables in my bootstrap.yml. I have added the environment variables to the circle.yml, although I keep getting the following types of error:

Caused by: java.lang.IllegalArgumentException: Could not resolve placeholder ‘SPRING-CLOUD-CONFIG-SERVER-ENCRYPT-ENABLED’ in value “${SPRING-CLOUD-CONFIG-SERVER-ENCRYPT-ENABLED}”

Does anyone have an idea on why the maven build is not finding the environment variables?


#2

So cancel that. I upgraded to CircleCI 2.0 and I was able to make everything work. I probably should have done that first.

If anyone wants to see a small spring boot repot example, check out https://github.com/k8s-spring-cloud/config-server


#3