mirror of
https://github.com/blakeblackshear/frigate.git
synced 2026-02-05 18:55:23 +03:00
Move requirements files and set intermediate targets
This commit is contained in:
parent
630334c520
commit
a2634895d6
2
.github/workflows/pull_request.yml
vendored
2
.github/workflows/pull_request.yml
vendored
@ -71,7 +71,7 @@ jobs:
|
|||||||
- name: Install requirements
|
- name: Install requirements
|
||||||
run: |
|
run: |
|
||||||
python3 -m pip install -U pip
|
python3 -m pip install -U pip
|
||||||
python3 -m pip install -r requirements-dev.txt
|
python3 -m pip install -r docker/main/requirements-dev.txt
|
||||||
- name: Check black
|
- name: Check black
|
||||||
run: |
|
run: |
|
||||||
black --check --diff frigate migrations docker *.py
|
black --check --diff frigate migrations docker *.py
|
||||||
|
|||||||
@ -47,7 +47,7 @@ FROM base_amd64 AS ov-converter
|
|||||||
ARG DEBIAN_FRONTEND
|
ARG DEBIAN_FRONTEND
|
||||||
|
|
||||||
# Install OpenVino Runtime and Dev library
|
# Install OpenVino Runtime and Dev library
|
||||||
COPY requirements-ov.txt /requirements-ov.txt
|
COPY docker/main/requirements-ov.txt /requirements-ov.txt
|
||||||
RUN apt-get -qq update \
|
RUN apt-get -qq update \
|
||||||
&& apt-get -qq install -y wget python3 python3-distutils \
|
&& apt-get -qq install -y wget python3 python3-distutils \
|
||||||
&& wget -q https://bootstrap.pypa.io/get-pip.py -O get-pip.py \
|
&& wget -q https://bootstrap.pypa.io/get-pip.py -O get-pip.py \
|
||||||
@ -140,10 +140,10 @@ RUN apt-get -qq update \
|
|||||||
RUN wget -q https://bootstrap.pypa.io/get-pip.py -O get-pip.py \
|
RUN wget -q https://bootstrap.pypa.io/get-pip.py -O get-pip.py \
|
||||||
&& python3 get-pip.py "pip"
|
&& python3 get-pip.py "pip"
|
||||||
|
|
||||||
COPY requirements.txt /requirements.txt
|
COPY docker/main/requirements.txt /requirements.txt
|
||||||
RUN pip3 install -r requirements.txt
|
RUN pip3 install -r requirements.txt
|
||||||
|
|
||||||
COPY requirements-wheels.txt /requirements-wheels.txt
|
COPY docker/main/requirements-wheels.txt /requirements-wheels.txt
|
||||||
RUN pip3 wheel --wheel-dir=/wheels -r requirements-wheels.txt
|
RUN pip3 wheel --wheel-dir=/wheels -r requirements-wheels.txt
|
||||||
|
|
||||||
|
|
||||||
@ -218,7 +218,7 @@ RUN apt-get update \
|
|||||||
&& apt-get install make -y \
|
&& apt-get install make -y \
|
||||||
&& rm -rf /var/lib/apt/lists/*
|
&& rm -rf /var/lib/apt/lists/*
|
||||||
|
|
||||||
RUN --mount=type=bind,source=./requirements-dev.txt,target=/workspace/frigate/requirements-dev.txt \
|
RUN --mount=type=bind,source=./docker/main/requirements-dev.txt,target=/workspace/frigate/requirements-dev.txt \
|
||||||
pip3 install -r requirements-dev.txt
|
pip3 install -r requirements-dev.txt
|
||||||
|
|
||||||
CMD ["sleep", "infinity"]
|
CMD ["sleep", "infinity"]
|
||||||
|
|||||||
@ -1,14 +1,16 @@
|
|||||||
target "deps" {
|
target deps {
|
||||||
dockerfile = "docker/main/Dockerfile"
|
dockerfile = "docker/main/Dockerfile"
|
||||||
platforms = ["linux/arm64"]
|
platforms = ["linux/arm64"]
|
||||||
|
target = "deps"
|
||||||
}
|
}
|
||||||
|
|
||||||
target rootfs {
|
target rootfs {
|
||||||
dockerfile = "docker/main/Dockerfile"
|
dockerfile = "docker/main/Dockerfile"
|
||||||
platforms = ["linux/arm64"]
|
platforms = ["linux/arm64"]
|
||||||
|
target = "rootfs"
|
||||||
}
|
}
|
||||||
|
|
||||||
target "rpi" {
|
target rpi {
|
||||||
dockerfile = "docker/rpi/Dockerfile"
|
dockerfile = "docker/rpi/Dockerfile"
|
||||||
contexts = {
|
contexts = {
|
||||||
deps = "target:deps",
|
deps = "target:deps",
|
||||||
|
|||||||
@ -9,7 +9,7 @@ ARG DEBIAN_FRONTEND
|
|||||||
ARG TARGETARCH
|
ARG TARGETARCH
|
||||||
|
|
||||||
# Add TensorRT wheels to another folder
|
# Add TensorRT wheels to another folder
|
||||||
COPY requirements-tensorrt.txt /requirements-tensorrt.txt
|
COPY docker/tensorrt/requirements.txt /requirements-tensorrt.txt
|
||||||
RUN mkdir -p /trt-wheels && pip3 wheel --wheel-dir=/trt-wheels -r /requirements-tensorrt.txt
|
RUN mkdir -p /trt-wheels && pip3 wheel --wheel-dir=/trt-wheels -r /requirements-tensorrt.txt
|
||||||
|
|
||||||
# Build TensorRT-specific library
|
# Build TensorRT-specific library
|
||||||
|
|||||||
@ -1,21 +1,25 @@
|
|||||||
target deps {
|
target deps {
|
||||||
dockerfile = "docker/main/Dockerfile"
|
dockerfile = "docker/main/Dockerfile"
|
||||||
platforms = ["linux/amd64"]
|
platforms = ["linux/amd64"]
|
||||||
|
target = "deps"
|
||||||
}
|
}
|
||||||
|
|
||||||
target rootfs {
|
target rootfs {
|
||||||
dockerfile = "docker/main/Dockerfile"
|
dockerfile = "docker/main/Dockerfile"
|
||||||
platforms = ["linux/amd64"]
|
platforms = ["linux/amd64"]
|
||||||
|
target = "rootfs"
|
||||||
}
|
}
|
||||||
|
|
||||||
target wheels {
|
target wheels {
|
||||||
dockerfile = "docker/main/Dockerfile"
|
dockerfile = "docker/main/Dockerfile"
|
||||||
platforms = ["linux/amd64"]
|
platforms = ["linux/amd64"]
|
||||||
|
target = "wheels"
|
||||||
}
|
}
|
||||||
|
|
||||||
target devcontainer {
|
target devcontainer {
|
||||||
dockerfile = "docker/main/Dockerfile"
|
dockerfile = "docker/main/Dockerfile"
|
||||||
platforms = ["linux/amd64"]
|
platforms = ["linux/amd64"]
|
||||||
|
target = "devcontainer"
|
||||||
}
|
}
|
||||||
|
|
||||||
target tensorrt {
|
target tensorrt {
|
||||||
@ -27,6 +31,7 @@ target tensorrt {
|
|||||||
wheels = "target:wheels"
|
wheels = "target:wheels"
|
||||||
}
|
}
|
||||||
platforms = ["linux/amd64"]
|
platforms = ["linux/amd64"]
|
||||||
|
target = "frigate-tensorrt"
|
||||||
}
|
}
|
||||||
|
|
||||||
target devcontainer-trt {
|
target devcontainer-trt {
|
||||||
@ -36,7 +41,8 @@ target devcontainer-trt {
|
|||||||
deps = "target:deps",
|
deps = "target:deps",
|
||||||
rootfs = "target:rootfs"
|
rootfs = "target:rootfs"
|
||||||
wheels = "target:wheels"
|
wheels = "target:wheels"
|
||||||
devcontainer = "target:devcontainer
|
devcontainer = "target:devcontainer"
|
||||||
}
|
}
|
||||||
platforms = ["linux/amd64"]
|
platforms = ["linux/amd64"]
|
||||||
|
target = "devcontainer-trt"
|
||||||
}
|
}
|
||||||
Loading…
Reference in New Issue
Block a user