-
Task
-
Resolution: Done
-
Medium
-
None
-
None
-
Policy 2022-08-31->2022-08-17, Policy 2022-08-31->2022-09-14
It should be possible to override the dockerfile used in maven builds, e.g.
mvn clean install -Pdocker -DdockerFile=/path/to/new/Dockerfile
While most builds already support setting the dockerfile location, the builds may fail, as
docker may look for files such as shell scripts in the new directory, instead of using project files under e.g. src/main/docker. Maven fabric8 plugin allows setting contextDir parameter to control that directory. Setting contextDir to ${project.basedir}/src/main/docker in this case would fix the issue.
This task is to ensure each dockerfile can be overridden and builds correctly.