You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When running with bazel run and setting correct profile everything works fine (profile is loaded)
export SPRING_PROFILES_ACTIVE=local
bazel run //orders:uber
...
...OrdersApplication : The following 1 profile is active: "local"
When generating jar with bazel build and running jar, it seems it cannot find resources/profiles
export SPRING_PROFILES_ACTIVE=local
bazel build //orders:uber_deploy.jar
java -jar bazel-bin/orders/uber_deploy.jar
...
...OrdersApplication : No active profile set, falling back to 1 default profile: default
I already tried other ways to set the profile, like using the command line -Dspring.profiles.active=local or --spring.profiles.active=local, but nothing seems to work.
Can anyone give some help on that?
The text was updated successfully, but these errors were encountered:
gabrielmirandat
changed the title
Profile problem when running bazel bazel build in java_binary
Profile issue when running bazel build command in java_binary
Dec 18, 2024
I am getting different behaviors when running a java_binary using bazel build and bazel run.
I already tried other ways to set the profile, like using the command line -Dspring.profiles.active=local or --spring.profiles.active=local, but nothing seems to work.
Can anyone give some help on that?
The text was updated successfully, but these errors were encountered: