I have a Maven project that creates several Maven artefacts, one of these Maven project also creates a Docker image.
Now my problem is, it is no problem to get standard dependencies that lies in for ex in Maven Central (local Nexus may be) with curl, but how I am going a previous artefact created in Maven build....
My first idea was naturally to load it from local repository like
ADD /Volumes/D/localrepo/org.test.artefact/1.0-SNAPSHOT/artefact-1.0-SNAPSHOT.jar .
but off course this does not work because it is not under Docker context...
I don't want to do relative path tricks because I don't want that thing gets broken during a refactoring. Later stage in the project, artefacts will most probably be in company Nexus, it will be less of a problem but at this stage I don't have this luxury.
So how do you deal with such a problem?