Access ARG between stages in Dockerfile

A temporary directory might be the solution, if I still want to use the OpenJDK docker image.