How to include a local language server in a dockerfile and build a docker image from it?

拜拜、爱过 提交于 2019-12-06 19:39:35

I might think that the problem lies in the ADD line. This adds the local file xtextls3 to your layer. However, the file cannot be found. I have the idea that you have to swap the first and second argument on the ADD-instruction.

It seems that I should be stating the path in relation to the context directory (current location I'm at in the command prompt). I placed my .jar file in the same folder where the Dockerfile is and changed the Dockerfile content as follows:

FROM barais/eclipse-xtend
ADD build/libs/dsl-language-server-ls.jar dsl-language-server-ls.jar
RUN sudo apt-get install socat
CMD socat TCP4-LISTEN:4417,reuseaddr,fork EXEC:"mydsl"

"build/libs/dsl-language-server-ls.jar" is the path+file, and "dsl-language-server-ls.jar" is the binary file that I require.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!