<legend id='ZVG9w'><style id='ZVG9w'><dir id='ZVG9w'><q id='ZVG9w'></q></dir></style></legend>
    <tfoot id='ZVG9w'></tfoot>

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

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

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

        Docker:该命令返回一个非零代码:137

        时间:2023-09-10

            <tbody id='2duh6'></tbody>
            1. <i id='2duh6'><tr id='2duh6'><dt id='2duh6'><q id='2duh6'><span id='2duh6'><b id='2duh6'><form id='2duh6'><ins id='2duh6'></ins><ul id='2duh6'></ul><sub id='2duh6'></sub></form><legend id='2duh6'></legend><bdo id='2duh6'><pre id='2duh6'><center id='2duh6'></center></pre></bdo></b><th id='2duh6'></th></span></q></dt></tr></i><div id='2duh6'><tfoot id='2duh6'></tfoot><dl id='2duh6'><fieldset id='2duh6'></fieldset></dl></div>
                <legend id='2duh6'><style id='2duh6'><dir id='2duh6'><q id='2duh6'></q></dir></style></legend>
              • <small id='2duh6'></small><noframes id='2duh6'>

                  <bdo id='2duh6'></bdo><ul id='2duh6'></ul>
                  <tfoot id='2duh6'></tfoot>
                • 本文介绍了Docker:该命令返回一个非零代码:137的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

                  问题描述

                  我的docker文件如下:

                  My docker file is as follows:

                  #Use python 3.6 image
                  FROM python:3.6
                  ENV PYTHONUNBUFFERED 1
                  
                  #install required packages
                  RUN apt-get update
                  RUN apt-get install libsasl2-dev libldap2-dev libssl-dev python3-dev psmisc -y
                  
                  #install a pip package
                  #Note: This pip package has a completely configured django project in it
                  RUN pip install <pip-package>
                  
                  #Run a script
                  #Note: Here appmanage.py is a file inside the pip installed location(site-packages), but it will be accessible directly without cd to the folder
                  RUN appmanage.py appconfig appadd.json
                  
                  #The <pip-packge> installed comes with a built in django package, so running it with following CMD
                  #Note: Here manage.py is present inside the pip package folder but it is accesible directly
                  CMD ["manage.py","runserver","0.0.0.0:8000"]
                  

                  当我跑步时:

                  sudo docker build -t test-app .
                  

                  dockerfile 中的步骤直到: RUN appmanage.py appconfig 按预期成功运行,但之后出现错误:

                  The steps in dockerfile till: RUN appmanage.py appconfig runs sucessfully as expected but after that i get the error:

                  The command '/bin/sh -c appmanage.py appconfig ' returned a non-zero code: 137
                  

                  当我在谷歌上搜索错误时,我得到的建议是内存不足.但我已经验证,系统(centos)有足够的内存.

                  When i google for the error i get suggestions like memory is not sufficient. But i have verified, the system(centos) is having enough memory.

                  RUN appmanage.py appconfig执行时的命令行输出为:

                  The commandline output during the execution of RUN appmanage.py appconfig is :

                  Step 7/8 : RUN appmanage.py appconfig
                   ---> Running in 23cffaacc81f
                  
                  ======================================================================================
                  configuring katana apps...
                   Please do not quit (or) kill the server manually, wait until the server closes itself...!
                  ======================================================================================
                  Performing system checks...
                  
                  System check identified no issues (0 silenced).
                  February 08, 2020 - 12:01:45
                  Django version 2.1.2, using settings 'katana.wui.settings'
                  Starting development server at http://127.0.0.1:9999/
                  Quit the server with CONTROL-C.
                  9999/tcp:
                      20Killed
                  

                  推荐答案

                  如前所述,RUN appmanage.py appconfig appAdd.json命令按预期运行成功,并报告System checkidentified没有问题(0 静音)..

                  As described, the command RUN appmanage.py appconfig appAdd.json run successfully as expected and reported that System check identified no issues (0 silenced)..

                  此外,命令坚持"杀死自己并返回退出代码 137.要使其工作的最小更改是将您的 Dockerfile 更新为类似于

                  Moreover, the command "insisted" on killing itself and return exit code of 137. The minimum changes for this to work is to update your Dockerfile to be like

                  ...
                  #Run a script
                  #Note: Here appmanage.py is a file inside the pip installed location(site-packages), but it will be accessible directly without cd to the folder
                  RUN appmanage.py appconfig appAdd.json || true
                  ...
                  

                  这将强制忽略上一个命令的返回退出代码并继续构建.

                  This will just forcefully ignore the return exit code from the previous command and carry on the build.

                  这篇关于Docker:该命令返回一个非零代码:137的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持html5模板网!

                  上一篇:ModuleNotFoundError:没有名为“versioneer"的模块 下一篇:“找不到 jpeg 的头文件或库文件"在 Alpine Li

                  相关文章

                  最新文章

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

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

                    1. <legend id='PY4oK'><style id='PY4oK'><dir id='PY4oK'><q id='PY4oK'></q></dir></style></legend>
                      • <bdo id='PY4oK'></bdo><ul id='PY4oK'></ul>