Integrating Python Poetry with Docker

后端 未结 7 552
轻奢々
轻奢々 2021-01-29 17:51

Can you give me an example of a Dockerfile in which I can install all the packages I need from poetry.lock and pyproject.toml into my imag

7条回答
  •  南笙
    南笙 (楼主)
    2021-01-29 18:10

    build image without python-poetry

    FROM abersh/no-pypoetry as requirements
    
    FROM python:3.7
    
    # ... yourself commands
    
    COPY --from=requirements /src/requirements.txt .
    
    RUN pip install -r requirements.txt
    
    # ... yourself commands
    

提交回复
热议问题