-
-
Notifications
You must be signed in to change notification settings - Fork 215
Expand file tree
/
Copy pathDockerfile
More file actions
25 lines (18 loc) · 626 Bytes
/
Dockerfile
File metadata and controls
25 lines (18 loc) · 626 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
FROM python:3.11 AS builder
WORKDIR /stitching
COPY setup.cfg pyproject.toml README.md .
COPY stitching/ ./stitching/
RUN pip install --no-cache-dir build && \
sed -i 's/opencv-python/opencv-python-headless/g' setup.cfg && \
python -m build
FROM python:3.11-slim
WORKDIR /stitching
COPY --from=builder /stitching/dist/stitching-*.whl .
RUN pip install --no-cache-dir stitching-*.whl && \
rm stitching-*.whl
# compile largestinteriorrectangle (JIT)
RUN python -c "import largestinteriorrectangle"
# provide the entrypoint, users need to mount a volume to /data
WORKDIR /data
ENTRYPOINT ["stitch"]
CMD ["-h"]