<tfoot id='SEhzp'></tfoot>

    <bdo id='SEhzp'></bdo><ul id='SEhzp'></ul>

<legend id='SEhzp'><style id='SEhzp'><dir id='SEhzp'><q id='SEhzp'></q></dir></style></legend>

  1. <i id='SEhzp'><tr id='SEhzp'><dt id='SEhzp'><q id='SEhzp'><span id='SEhzp'><b id='SEhzp'><form id='SEhzp'><ins id='SEhzp'></ins><ul id='SEhzp'></ul><sub id='SEhzp'></sub></form><legend id='SEhzp'></legend><bdo id='SEhzp'><pre id='SEhzp'><center id='SEhzp'></center></pre></bdo></b><th id='SEhzp'></th></span></q></dt></tr></i><div id='SEhzp'><tfoot id='SEhzp'></tfoot><dl id='SEhzp'><fieldset id='SEhzp'></fieldset></dl></div>

    <small id='SEhzp'></small><noframes id='SEhzp'>

      如何使用 docker 容器中的 docker 文件运行 jar 文件

      How to run jar file using docker file in docker container(如何使用 docker 容器中的 docker 文件运行 jar 文件)
          <tbody id='wzEru'></tbody>
        <i id='wzEru'><tr id='wzEru'><dt id='wzEru'><q id='wzEru'><span id='wzEru'><b id='wzEru'><form id='wzEru'><ins id='wzEru'></ins><ul id='wzEru'></ul><sub id='wzEru'></sub></form><legend id='wzEru'></legend><bdo id='wzEru'><pre id='wzEru'><center id='wzEru'></center></pre></bdo></b><th id='wzEru'></th></span></q></dt></tr></i><div id='wzEru'><tfoot id='wzEru'></tfoot><dl id='wzEru'><fieldset id='wzEru'></fieldset></dl></div>
        <tfoot id='wzEru'></tfoot><legend id='wzEru'><style id='wzEru'><dir id='wzEru'><q id='wzEru'></q></dir></style></legend>

      • <small id='wzEru'></small><noframes id='wzEru'>

        • <bdo id='wzEru'></bdo><ul id='wzEru'></ul>

                本文介绍了如何使用 docker 容器中的 docker 文件运行 jar 文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

                问题描述

                我编写了 docker 文件来运行 jar 文件,它没有创建日志文件,因为下面的控制台是我的 docker 文件

                I write the docker file for run the jar file and it does not create the log file for see the console below is my docker file

                From ubuntu 
                RUN apt-get update && 
                    apt-get upgrade -y && 
                    apt-get install -y  software-properties-common && 
                    add-apt-repository ppa:webupd8team/java -y && 
                    apt-get update && 
                    echo oracle-java8-installer shared/accepted-oracle-license-v1-1 select true | /usr/bin/debconf-set-selections && 
                    apt-get install -y oracle-java8-installer && 
                    apt-get clean
                VOLUME /temp
                RUN apt-get install -y vim
                ADD real_estate_false.jar /real_estate_false.jar
                COPY real_estate_false_lib /real_estate_false_lib
                COPY resources /resources
                COPY testxml /testxml
                CMD ["java","-jar","/real_estate_false.jar",">","var/log/jar.log"]
                

                推荐答案

                要在 docker 中运行 myapp.jar(例如,避免在主机上安装 java),您可以运行:

                To just run myapp.jar in docker (e.g. to avoid installing java on the host) you can just run:

                docker run -v `pwd`:/mnt java:8 java -jar /mnt/myapp.jar
                

                这篇关于如何使用 docker 容器中的 docker 文件运行 jar 文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

                本站部分内容来源互联网,如果有图片或者内容侵犯了您的权益,请联系我们,我们会在确认后第一时间进行删除!

                相关文档推荐

                How to send data to COM PORT using JAVA?(如何使用 JAVA 向 COM PORT 发送数据?)
                How to make a report page direction to change to quot;rtlquot;?(如何使报表页面方向更改为“rtl?)
                Use cyrillic .properties file in eclipse project(在 Eclipse 项目中使用西里尔文 .properties 文件)
                Is there any way to detect an RTL language in Java?(有没有办法在 Java 中检测 RTL 语言?)
                How to load resource bundle messages from DB in Java?(如何在 Java 中从 DB 加载资源包消息?)
                How do I change the default locale settings in Java to make them consistent?(如何更改 Java 中的默认语言环境设置以使其保持一致?)

                    <bdo id='ZfA11'></bdo><ul id='ZfA11'></ul>

                      <tfoot id='ZfA11'></tfoot>

                      <i id='ZfA11'><tr id='ZfA11'><dt id='ZfA11'><q id='ZfA11'><span id='ZfA11'><b id='ZfA11'><form id='ZfA11'><ins id='ZfA11'></ins><ul id='ZfA11'></ul><sub id='ZfA11'></sub></form><legend id='ZfA11'></legend><bdo id='ZfA11'><pre id='ZfA11'><center id='ZfA11'></center></pre></bdo></b><th id='ZfA11'></th></span></q></dt></tr></i><div id='ZfA11'><tfoot id='ZfA11'></tfoot><dl id='ZfA11'><fieldset id='ZfA11'></fieldset></dl></div>

                      <small id='ZfA11'></small><noframes id='ZfA11'>

                      • <legend id='ZfA11'><style id='ZfA11'><dir id='ZfA11'><q id='ZfA11'></q></dir></style></legend>

                            <tbody id='ZfA11'></tbody>