Skip to content

Commit

Permalink
sources
Browse files Browse the repository at this point in the history
  • Loading branch information
hawkeye217 committed Oct 7, 2024
1 parent 3f289d5 commit ce80aeb
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 4 deletions.
11 changes: 7 additions & 4 deletions docker/main/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,13 @@ RUN --mount=type=tmpfs,target=/tmp --mount=type=tmpfs,target=/var/cache/apt \
--mount=type=cache,target=/root/.ccache \
/deps/build_nginx.sh

# Build sqlite_vec from source
COPY docker/main/build_sqlite_vec.sh /deps/build_sqlite_vec.sh
RUN --mount=type=tmpfs,target=/tmp --mount=type=tmpfs,target=/var/cache/apt \
--mount=type=bind,source=docker/main/build_sqlite_vec.sh,target=/deps/build_sqlite_vec.sh \
--mount=type=cache,target=/root/.ccache \
/deps/build_sqlite_vec.sh

FROM scratch AS go2rtc
ARG TARGETARCH
WORKDIR /rootfs/usr/local/go2rtc/bin
Expand Down Expand Up @@ -167,10 +174,6 @@ RUN pip3 install -r /requirements.txt
COPY docker/main/build_pysqlite3.sh /build_pysqlite3.sh
RUN /build_pysqlite3.sh

# Build sqlite_vec from source
COPY docker/main/build_sqlite_vec.sh /build_sqlite_vec.sh
RUN /build_sqlite_vec.sh

COPY docker/main/requirements-wheels.txt /requirements-wheels.txt
RUN pip3 wheel --wheel-dir=/wheels -r /requirements-wheels.txt

Expand Down
2 changes: 2 additions & 0 deletions docker/main/build_sqlite_vec.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@ set -euxo pipefail

SQLITE_VEC_VERSION="0.1.3"

cp /etc/apt/sources.list /etc/apt/sources.list.d/sources-src.list
sed -i 's|deb http|deb-src http|g' /etc/apt/sources.list.d/sources-src.list
apt-get update
apt-get -yqq build-dep sqlite3 gettext

Expand Down

0 comments on commit ce80aeb

Please sign in to comment.