Stream: hapi
Topic: Docker from image with custom properties
Veliyan Georgiev (Jul 31 2020 at 14:29):
Does anybody know how to use a Dockerfile inheriting a specific release and add custom hapi.properties file?
FROM hapiproject/hapi:v4.2.0
... what goes here to use host hapi.proerties ????
Richard Stanley (Jul 31 2020 at 19:21):
I’ve seen mounting the properties file at runtime, such as in a docker-compose. This makes it possible to change server addresses etc for each instance of a container rather than baking it into the image.
Richard Stanley (Jul 31 2020 at 19:26):
To do so, you set JAVA_OPTS='-Dhapi.properties=/some/path/to/hapi.properties' in the docker-compose, and then make sure to mount a volume onto that path.
Last updated: Apr 12 2022 at 19:14 UTC