java - When using Maven, how can I separate variables for local/dev/production? -
i'd have single maven build produce artifact can used on local machine, our dev environment, staging environment, or production. since we're talking production, means db credentials can't in artifact anywhere.
this spring app we're using maven resource filtering , profiles (local
, dev
, stage
, prod
) filter properties in application.properties file , other files (email templates, etc). have build separate artifact each environment.
we have been able db passwords out of pom using @propertysource
annotation still seems we're missing must common problem.
i've been able find similar questions answers seem have problem or 2 - common of having sensitive properties production in artifact.
Comments
Post a Comment