mirror of
https://github.com/blakeblackshear/frigate.git
synced 2026-04-29 10:07:41 +03:00
Enable debug builds with dev reqs installed
This commit is contained in:
parent
9009ad3f00
commit
e6ca66b2f2
2
.github/workflows/pull_request.yml
vendored
2
.github/workflows/pull_request.yml
vendored
@ -107,7 +107,7 @@ jobs:
|
|||||||
- name: Set up Docker Buildx
|
- name: Set up Docker Buildx
|
||||||
uses: docker/setup-buildx-action@v3
|
uses: docker/setup-buildx-action@v3
|
||||||
- name: Build
|
- name: Build
|
||||||
run: make
|
run: make debug
|
||||||
- name: Run mypy
|
- name: Run mypy
|
||||||
run: docker run --rm --entrypoint=python3 frigate:latest -u -m mypy --config-file frigate/mypy.ini frigate
|
run: docker run --rm --entrypoint=python3 frigate:latest -u -m mypy --config-file frigate/mypy.ini frigate
|
||||||
- name: Run tests
|
- name: Run tests
|
||||||
|
|||||||
6
Makefile
6
Makefile
@ -20,6 +20,12 @@ local: version
|
|||||||
--tag frigate:latest \
|
--tag frigate:latest \
|
||||||
--load
|
--load
|
||||||
|
|
||||||
|
debug: version
|
||||||
|
docker buildx build --target=frigate --file docker/main/Dockerfile . \
|
||||||
|
--build-arg DEBUG=true \
|
||||||
|
--tag frigate:latest \
|
||||||
|
--load
|
||||||
|
|
||||||
amd64:
|
amd64:
|
||||||
docker buildx build --target=frigate --file docker/main/Dockerfile . \
|
docker buildx build --target=frigate --file docker/main/Dockerfile . \
|
||||||
--tag $(IMAGE_REPO):$(VERSION)-$(COMMIT_HASH) \
|
--tag $(IMAGE_REPO):$(VERSION)-$(COMMIT_HASH) \
|
||||||
|
|||||||
@ -148,6 +148,7 @@ RUN --mount=type=bind,source=docker/main/install_s6_overlay.sh,target=/deps/inst
|
|||||||
FROM base AS wheels
|
FROM base AS wheels
|
||||||
ARG DEBIAN_FRONTEND
|
ARG DEBIAN_FRONTEND
|
||||||
ARG TARGETARCH
|
ARG TARGETARCH
|
||||||
|
ARG DEBUG=false
|
||||||
|
|
||||||
# Use a separate container to build wheels to prevent build dependencies in final image
|
# Use a separate container to build wheels to prevent build dependencies in final image
|
||||||
RUN apt-get -qq update \
|
RUN apt-get -qq update \
|
||||||
@ -177,7 +178,12 @@ 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 docker/main/requirements.txt /requirements.txt
|
COPY docker/main/requirements.txt /requirements.txt
|
||||||
RUN pip3 install -r /requirements.txt
|
COPY docker/main/requirements-dev.txt /requirements-dev.txt
|
||||||
|
|
||||||
|
RUN pip3 install -r /requirements.txt && \
|
||||||
|
if [ "$DEBUG" = "true" ]; then \
|
||||||
|
pip3 install -r /requirements-dev.txt; \
|
||||||
|
fi
|
||||||
|
|
||||||
# Build pysqlite3 from source
|
# Build pysqlite3 from source
|
||||||
COPY docker/main/build_pysqlite3.sh /build_pysqlite3.sh
|
COPY docker/main/build_pysqlite3.sh /build_pysqlite3.sh
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user