Dockerfile 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. FROM SXKJ:32775/yiliocr-layout:test-2023-08-26_11-57-27
  2. WORKDIR /workspace
  3. RUN rm -rf ./*
  4. ADD requirements.txt .
  5. RUN ln -s /opt/conda/bin/pip /usr/local/bin/pip
  6. RUN pip install -r requirements.txt -i https://mirror.baidu.com/pypi/simple
  7. # ADD environment.yml /environment.yml
  8. # RUN sed -i 's#- paddlepaddle#- paddlepaddle-gpu==2.3.0.post110#g' /environment.yml && cat /environment.yml
  9. #RUN conda update -n base -c defaults conda -y && conda env update -f /environment.yml && rm -rf /root/.cache
  10. # RUN mamba update -n base -c defaults conda -y && mamba env create -f /environment.yml && rm -rf /root/.cache
  11. RUN echo "\
  12. [program:be]\n\
  13. directory=/workspace\n\
  14. command=/opt/conda/bin/python run.py \n\
  15. autorestart=true\n\
  16. startretries=0\n\
  17. redirect_stderr=true\n\
  18. stdout_logfile=/var/log/be.log\n\
  19. stdout_logfile_maxbytes=50MB\n\
  20. environment=CUDA_VISIBLE_DEVICES=0,PYTHONPATH=/worksapce/yolov7\n\
  21. " > /etc/supervisor/conf.d/be.conf
  22. # envs/py38/
  23. RUN git clone http://gogs.soaringnova.com/sxwl_DL/yolov7.git
  24. RUN wget ftp://192.168.199.31/yiliv7_718.pt
  25. # RUN wget ftp://192.168.199.31/logo.pt
  26. ADD . /workspace
  27. EXPOSE 8080
  28. # RUN mamba install -y jupyterlab -n base && mamba init zsh
  29. # RUN /opt/conda/bin/jupyter notebook --generate-config && \
  30. # echo "c.NotebookApp.password='argon2:\$argon2id\$v=19\$m=10240,t=10,p=8\$+zIUCF9Uk2FiCHlV8njX5A\$I5Mm/64DORArcXYTXWRVng'">>/root/.jupyter/jupyter_notebook_config.py
  31. # RUN mkdir -p /data && echo "\
  32. # [program:jupyter]\n\
  33. # directory=/data\n\
  34. # command=/opt/conda/bin/jupyter lab --ip 0.0.0.0 --port 8888 --allow-root --no-browser \n\
  35. # autorestart=true\n\
  36. # startretries=0\n\
  37. # redirect_stderr=true\n\
  38. # stdout_logfile=/dev/stdout\n\
  39. # stdout_logfile_maxbytes=0\n\
  40. # " > /etc/supervisor/conf.d/jupyter.conf
  41. # EXPOSE 8888