title: Springboot application in pivotal Cloud with different environments
body: <p>I am using a Pivotal Cloud foundry with different testing environments (test, QA, UAT, PROD) Spring boot application
  I have created multiple properties files(Each pointing to different db) like</p>
  <pre><code>application-dev.properties
  application-test.properties
  application-qa.properties
  application-uat.properties
  application-prod.properties
  </code></pre>
  <p>if it is in local i am running by seting <code>-Dspring.progiles.active=test/qa/uat/prod</code></p>
  <pre class="lang-sh prettyprint-override"><code> mvn clean compile springboot:run -Dspring.progiles.active=test
  </code></pre>
  <p>How can I make it customize my application to use the specific properties file based on the environment in the cloud?
  What all the configurations do I need to change? Below is my <code>application.properties</code> file.</p>
  <pre><code>spring.profiles.active=test
  
  spring.datasource.url=
  spring.datasource.username=
  spring.datasource.password=
  spring.datasource.driver-class =org.hibernate.dialect.TeradataDialect
  spring.jpa.database-platform=org.hibernate.dialect.TeradataDialect
  spring.jpa.show-sql = true
  spring.jpa.hibernate.ddl-auto = none
  spring.jpa.properties.hibernate.default_schema=
  
  spring.jpa.properties.hibernate.dialect= org.hibernate.dialect.TeradataDialect
  server.port=9090
  
  logging.level.org.springframework.web=INFO
  logging.level.org.hibernate=INFO
  logging.file=myapplication.log
  </code></pre>
  <p>or do I need to change whenever I move to higher environments?</p>
  <p>Thanks in advance.</p>