I am trying to have one, exactly one profile active on my SpringBoot application. I used to override the configureProfiles
method, so if more than one profiles where active the application did not run. In case no profile was active, I added a default profile. The profile I wanted to be active has to be defined using SPRING_PROFILES_ACTIVE
environmental variable.
With the last versions (2.5.x) of SpringBoot configureProfiles
is empty and when called, the active profile defined using SPRING_PROFILES_ACTIVE
is not even loaded.
Any idea how I can have exactly one (no more, no less) profile active on SpringBoot?