Runtime environment variables issue (regarding Procfile) #252
Replies: 1 comment 1 reply
-
Environment variables set when you run The other option is to use the environment variables buildpack and embed the env variables in the image. That can be done by following the instructions here. As far as Procfile. We don't really recommend using that with the Java buildpacks. You can nothing will stop you, but it adds unnecessary complication and can easily break things. Instead, what I would suggest is that you set flags to the JVM by setting Two other notes:
|
Beta Was this translation helpful? Give feedback.
-
Hello everyone, I am currently facing an issue as my image has this condition to use this environment variable during the runtime
-Dspring.config.additional-location=file:./data/labels.properties -XX:InitialRAMPercentage=35.0 -XX:MaxRAMPercentage=70.0 -XX:+PrintGCDetails -Xloggc:/tmp/gc-${HOSTNAME}-%t.log -XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath=/tmp/dump-${HOSTNAME}-%t.hprof
As I am using paketo buildpacks to build this image I am getting a predefined process type which has the command to execute the Jar
How can I add the environment variables that should work on runtime of that image ?
I read about adding the runtime env in project.toml file but I didnt get any clear idea on this , is there any example to show how I can achieve this runtime env in project.toml file, It would be very helpful for me.
I also took a look on Procfile , say I am running java command in that procfile Do I need java to be installed on my run stack image to execute the java commands which is inside my procfile ?
Thanks
Beta Was this translation helpful? Give feedback.
All reactions