softcite / software-mentions

Softcite software mention recognizer, finding mentions and citations to software from within the academic literature
Apache License 2.0
68 stars 11 forks source link

Docker build hangs indefinitely #28

Open jameshowison opened 1 year ago

jameshowison commented 1 year ago

Trying to build the image myself.

Docker hangs after

=> [stage-1 38/38] RUN ./gradlew clean assemble install --no-daemon --  390.8s
 => => # You can use '--warning-mode all' to show the individual deprecation wa
 => => # rnings and determine if they come from your own scripts or plugins.   
 => => # See https://docs.gradle.org/7.2/userguide/command_line_interface.html#
 => => # sec:command_line_warnings                                             
 => => # BUILD SUCCESSFUL in 4m 4s                                             
 => => # 15 actionable tasks: 15 executed    

The next command in the Dockerfile.software is

CMD ["sh", "-c", "java --add-opens java.base/java.lang=ALL-UNNAMED -jar build/libs/software-mentions-0.8.0-SNAPSHOT-onejar.jar server resources/config/config.yml"]

The instructions (on the README) say to build with:

docker build -t grobid/software-mentions:0.7.3-SNAPSHOT --build-arg GROBID_VERSION=0.7.3-SNAPSHOT --file Dockerfile.software .

I noted the discrepancy between 0.8.0-SNAPSHOT and 0.7.3-SNAPSHOT in the --build-arg and changed both on the commandline version. Sadly that didn't fix it :(

Any ideas?

jameshowison commented 1 year ago

I commented out that line built the image, then I ran that line in the container. That command did all its tasks but then is waiting for something more. I think it's in some interactive mode?

jameshowison commented 1 year ago

Oddly, this solved for me by removing --no-daemon so that line 141 reads RUN ./gradlew clean assemble install --stacktrace --info -x test

With that the gradlew command returns and doesn't sit idle. Opposite of what one might expect!