Working with both extensions now
This commit is contained in:
parent
44dd70f0d2
commit
6b161e500c
3 changed files with 15 additions and 2 deletions
|
@ -22,11 +22,12 @@ RUN git clone --branch $PGVECTOR_REF --depth 1 https://github.com/pgvector/pgvec
|
||||||
WORKDIR /tmp/pgvector/
|
WORKDIR /tmp/pgvector/
|
||||||
RUN make && make install
|
RUN make && make install
|
||||||
|
|
||||||
COPY docker-entrypoint-initdb.d/* /docker-entrypoint-initdb.d/
|
|
||||||
COPY --from=timebuild /go/bin/* /usr/local/bin/
|
COPY --from=timebuild /go/bin/* /usr/local/bin/
|
||||||
RUN git clone --branch $TS_REF https://github.com/timescale/timescaledb /tmp/timescaledb
|
RUN git clone --branch $TS_REF https://github.com/timescale/timescaledb /tmp/timescaledb
|
||||||
WORKDIR /tmp/timescaledb
|
WORKDIR /tmp/timescaledb
|
||||||
RUN ./bootstrap -DCMAKE_BUILD_TYPE=RelWithDebInfo -DREGRESS_CHECKS=OFF -DTAP_CHECKS=OFF -DGENERATE_DOWNGRADE_SCRIPT=ON -DWARNINGS_AS_ERRORS=OFF -DPROJECT_INSTALL_METHOD="docker"
|
RUN ./bootstrap -DCMAKE_BUILD_TYPE=RelWithDebInfo -DREGRESS_CHECKS=OFF -DTAP_CHECKS=OFF -DGENERATE_DOWNGRADE_SCRIPT=ON -DWARNINGS_AS_ERRORS=OFF -DPROJECT_INSTALL_METHOD="docker"
|
||||||
RUN cd build && make && make install
|
RUN cd build && make && make install
|
||||||
|
RUN sed -r -i "s/[#]*\s*(shared_preload_libraries)\s*=\s*'(.*)'/\1 = 'timescaledb,\2'/;s/,'/'/" /usr/share/postgresql/$PG_MAJOR/postgresql.conf.sample
|
||||||
|
COPY docker-entrypoint-initdb.d/* /docker-entrypoint-initdb.d/
|
||||||
WORKDIR /
|
WORKDIR /
|
||||||
|
|
||||||
|
|
12
docker-compose.yml
Normal file
12
docker-compose.yml
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
version: '3.1'
|
||||||
|
|
||||||
|
services:
|
||||||
|
|
||||||
|
db:
|
||||||
|
build: .
|
||||||
|
restart: unless-stopped
|
||||||
|
environment:
|
||||||
|
POSTGRES_PASSWORD: pass
|
||||||
|
POSTGRES_USER: user
|
||||||
|
POSTGRES_DB: aimach
|
||||||
|
|
|
@ -22,7 +22,7 @@ if [ -z "${POSTGRESQL_CONF_DIR:-}" ]; then
|
||||||
fi
|
fi
|
||||||
|
|
||||||
cat <<EOF >${create_sql}
|
cat <<EOF >${create_sql}
|
||||||
CREATE EXTENSION IF NOT EXISTS pgvector CASCADE;
|
CREATE EXTENSION IF NOT EXISTS vector CASCADE;
|
||||||
EOF
|
EOF
|
||||||
|
|
||||||
if [ -z "${POSTGRESQL_PASSWORD:-}" ]; then
|
if [ -z "${POSTGRESQL_PASSWORD:-}" ]; then
|
||||||
|
|
Loading…
Add table
Reference in a new issue