6

I have deployed my war file on AWS's Elastic Beanstalk as a java app.

I want to specify on AWS : spring.profiles.active like I do when I execute:

java -jar -Dspring.profiles.active=prod target/gaming-boost-0.0.1-SNAPSHOT.war

I can only configure "Environment Property" on "Configuration"

jrbedard
  • 3,662
  • 5
  • 30
  • 34
Z3nk
  • 365
  • 4
  • 17

2 Answers2

6

Set below environment variable in ElasticBeanStalk

SPRING_PROFILES_ACTIVE=prod
Vaibhav
  • 2,073
  • 4
  • 23
  • 26
1

Take a look at https://stackoverflow.com/a/39021794/2135973

The casing is different when set as an Environment Variable versus the command line property. Try setting SPRING_PROFILES_ACTIVE in your EB Configuration.

Community
  • 1
  • 1
Adam Erstelle
  • 2,454
  • 3
  • 21
  • 35