Using Spring-boot we can store config parameters for different environments in Profile specific properties file, however that makes config part of code which is what 12-factor principles doesn't recommend .
Rather, 12 -factor recommends storing config(here, config specifically means parameters whose value varies across different environments) in environment.
What are pros/cons of storing config in environment Vs profile-specific properties files ?
Configuration in code
Pros:
Cons:
Configuration in environment
Pros:
Cons:
Nothing is black and white, you can always use a compromise solution which mixes both approaches. One part of your configuration might be suitable to keep it with the source code, while another may be kept outside. As usual in programming it depends on your needs.