Skip to content

Commit

Permalink
Merge pull request #246 from raaymax/docker-docs-update
Browse files Browse the repository at this point in the history
  • Loading branch information
ramedina86 authored Feb 16, 2024
2 parents 0171975 + fb34c53 commit e2c1f2e
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
6 changes: 3 additions & 3 deletions apps/hello/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
FROM python:3-slim AS compile-image
FROM python:3.10-slim AS compile-image
RUN apt-get update -y && mkdir /app && python3 -m venv /app/venv
ENV PATH="/app/venv/bin:$PATH"
COPY . /app
WORKDIR /app
RUN pip3 install 'streamsync[ds]' && pip3 install -r requirements.txt

FROM python:3-slim AS run-image
FROM python:3.10-slim AS run-image
RUN apt-get update -y && mkdir /app
COPY --from=compile-image /app /app
ENV PATH="/app/venv/bin:$PATH"
WORKDIR /app

ENTRYPOINT [ "streamsync", "run" ]
EXPOSE 5000
CMD [ ".", "--port", "5000", "--host", "0.0.0.0" ]
CMD [ ".", "--port", "5000", "--host", "0.0.0.0" ]
4 changes: 2 additions & 2 deletions docs/docs/deploy-with-docker.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,14 +17,14 @@ A Dockerfile is a file with instructions that tell Docker how to build your imag
You can use the following as-is, or as a starting point. It should be saved in your app's folder, together with `requirements.txt`, `main.py` and `ui.json`.

```docker
FROM python:3-slim AS compile-image
FROM python:3.10-slim AS compile-image
RUN apt-get update -y && mkdir /app && python3 -m venv /app/venv
ENV PATH="/app/venv/bin:$PATH"
COPY . /app
WORKDIR /app
RUN pip3 install streamsync && pip3 install -r requirements.txt
FROM python:3-slim AS run-image
FROM python:3.10-slim AS run-image
RUN apt-get update -y && mkdir /app
COPY --from=compile-image /app /app
ENV PATH="/app/venv/bin:$PATH"
Expand Down

0 comments on commit e2c1f2e

Please sign in to comment.