I need to execute a docker run inside a console application in Java. I build the Dockerfile with base image gradle:6.8.3-jdk15 before the application starts. This is the expected flow: On host: I create a new Process that runs my docker run command. Inside container: the entrypoint is gradle –daemon, after the daemon is started ..
I wrote a Dockerfile that should build a windows image with java jdk inside. The entrypoint is pretty simple, it is just launching the java.exe. # escape=` FROM mcr.microsoft.com/windows/servercore:ltsc2016 COPY .install_filesjdk-8u221-windows-x64.exe C:jdk-8u221-windows-x64.exe COPY .install_filesagent.jar C:agent.jar SHELL [“powershell”, “-command”] RUN Start-Process -Filepath C:jdk-8u221-windows-x64.exe -passthru -wait -argumentlist “/s,INSTALLDIR=C:Java,/L,java.log” ; ` $env:Path += ‘;C:Javabin’ SHELL [“cmd”, “/S”, “/C”] ..