Dockerfile-pyinstall 243 B

12345678910111213
  1. FROM python:3.8 as base
  2. WORKDIR /app
  3. ADD . ./app
  4. RUN pip install -r requirements.txt
  5. FROM base as builder
  6. RUN pip install pyinstaller
  7. RUN pyinstaller -F -c demo.py
  8. FROM base as runner
  9. COPY --from=builder . /app/
  10. CMD [ "python", "main.py" ]