Skip to content

Commit c348b92

Browse files
committed
Merge branch 'main' into upgrade_CI
2 parents c8edb58 + 1ed1a48 commit c348b92

File tree

6 files changed

+76
-7
lines changed

6 files changed

+76
-7
lines changed

.github/workflows/smoke-test.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,10 @@ jobs:
8585
echo "Test pgautofailover Extension"
8686
psql -c "CREATE EXTENSION pgautofailover CASCADE;"
8787
psql -c "SELECT pgautofailover.formation_settings();"
88+
89+
echo "Test HyperLogLog Extension"
90+
psql -c "CREATE EXTENSION hll;"
91+
psql -c "select hll_hash_text('hello world');"
8892
break
8993
fi
9094
sleep 1

Dockerfile

Lines changed: 30 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -249,7 +249,7 @@ RUN apk add --no-cache --virtual .zombodb-build-deps \
249249
&& gem install --no-document fpm \
250250
&& curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | bash -s -- -y \
251251
&& PATH=$HOME/.cargo/bin:$PATH \
252-
&& cargo install cargo-pgrx --version 0.8.3 \
252+
&& cargo install cargo-pgrx --version 0.9.3 \
253253
&& cargo pgrx init --${PG_VER}=$(which pg_config) \
254254
&& git clone https://github.com/zombodb/zombodb.git \
255255
&& cd ./zombodb \
@@ -312,4 +312,32 @@ RUN set -eux \
312312
# clean
313313
&& cd / \
314314
&& rm -rf /tmp/pg_auto_failove-${PG_AUTO_FAILOVER_VERSION} /tmp/pg_auto_failove-${PG_AUTO_FAILOVER_VERSION}.zip \
315-
&& apk del .pg_auto_failover-build-deps
315+
&& apk del .pg_auto_failover-build-deps
316+
317+
318+
## Adding postgresql-hll
319+
ARG POSTGRES_HLL_VERSION
320+
RUN set -eux \
321+
&& apk add --no-cache --virtual .postgresql-hll-build-deps \
322+
openssl-dev \
323+
zstd-dev \
324+
lz4-dev \
325+
zlib-dev \
326+
make \
327+
git \
328+
clang15 \
329+
gawk \
330+
llvm15 \
331+
g++ \
332+
musl-dev \
333+
# build postgresql-hll
334+
&& wget -O /tmp/postgresql-hll-${POSTGRES_HLL_VERSION}.zip "https://github.com/citusdata/postgresql-hll/archive/refs/tags/v${POSTGRES_HLL_VERSION}.zip" \
335+
&& unzip /tmp/postgresql-hll-${POSTGRES_HLL_VERSION}.zip -d /tmp \
336+
&& cd /tmp/postgresql-hll-${POSTGRES_HLL_VERSION} \
337+
&& make \
338+
&& make install \
339+
# clean
340+
&& cd / \
341+
&& rm -rf /tmp/postgresql-hll-${POSTGRES_HLL_VERSION} /tmp/postgresql-hll-${POSTGRES_HLL_VERSION}.zip \
342+
&& apk del .postgresql-hll-build-deps
343+

Makefile

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ CITUS_VERSION="11.2.0"
77
POSTGIS_VERSION=3.3.2
88
PG_REPACK_VERSION = 1.4.8
99
PG_AUTO_FAILOVER_VERSION = 2.0
10+
POSTGRES_HLL_VERSION = 2.17
1011
POSTGIS_SHA256=2a6858d1df06de1c5f85a5b780773e92f6ba3a5dc09ac31120ac895242f5a77b
1112
PG_VER_NUMBER=$(shell echo $(PG_VER) | cut -c3-)
1213
TS_VERSION=main
@@ -33,7 +34,8 @@ DOCKER_BUILD_ARGS = --build-arg PG_VERSION=$(PG_VER_NUMBER) \
3334
--build-arg POSTGIS_VERSION=$(POSTGIS_VERSION) \
3435
--build-arg PG_AUTO_FAILOVER_VERSION=$(PG_AUTO_FAILOVER_VERSION) \
3536
--build-arg POSTGIS_VERSION=$(POSTGIS_VERSION) \
36-
--build-arg POSTGIS_SHA256=$(POSTGIS_SHA256)
37+
--build-arg POSTGIS_SHA256=$(POSTGIS_SHA256) \
38+
--build-arg POSTGRES_HLL_VERSION=$(POSTGRES_HLL_VERSION)
3739

3840
default: image
3941

bitnami/Dockerfile

Lines changed: 34 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -205,6 +205,39 @@ RUN apt-get update \
205205
/tmp/* \
206206
/var/tmp/*
207207

208+
## Adding postgresql-hll
209+
ARG POSTGRES_HLL_VERSION
210+
RUN apt-get update \
211+
&& apt-get install -y unzip \
212+
build-essential \
213+
liblz4-dev \
214+
zlib1g-dev \
215+
libedit-dev \
216+
libssl-dev \
217+
wget \
218+
# build postgresql-hll
219+
&& wget -O /tmp/postgresql-hll-${POSTGRES_HLL_VERSION}.zip "https://github.com/citusdata/postgresql-hll/archive/refs/tags/v${POSTGRES_HLL_VERSION}.zip" \
220+
&& unzip /tmp/postgresql-hll-${POSTGRES_HLL_VERSION}.zip -d /tmp \
221+
&& cd /tmp/postgresql-hll-${POSTGRES_HLL_VERSION} \
222+
&& make \
223+
&& make install \
224+
# clean
225+
&& cd / \
226+
&& rm -rf /tmp/postgresql-hll-${POSTGRES_HLL_VERSION} /tmp/postgresql-hll-${POSTGRES_HLL_VERSION}.zip \
227+
&& apt-get autoremove --purge -y \
228+
unzip \
229+
build-essential \
230+
liblz4-dev \
231+
zlib1g-dev \
232+
libedit-dev \
233+
libssl-dev \
234+
wget \
235+
&& apt-get clean -y \
236+
&& rm -rf \
237+
/var/lib/apt/lists/* \
238+
/tmp/* \
239+
/var/tmp/*
240+
208241
# Install zombodb extension
209242
RUN apt-get update -y -qq --fix-missing \
210243
&& apt-get install -y wget gnupg \
@@ -234,7 +267,7 @@ RUN apt-get update -y -qq --fix-missing \
234267
&& export PATH="/.cargo/bin:$PATH" \
235268
&& export PGRX_HOME="/.pgrx/" \
236269
&& mkdir -p $PGRX_HOME \
237-
&& cargo install cargo-pgrx --version 0.8.3 \
270+
&& cargo install cargo-pgrx --version 0.9.3 \
238271
&& cargo pgrx init --pg${PG_MAJOR}=/opt/bitnami/postgresql/bin/pg_config \
239272
&& git clone https://github.com/zombodb/zombodb.git \
240273
&& cd zombodb \

bitnami/Makefile

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ PG_MAJOR=15
99
POSTGIS_VERSION=3.3.3+dfsg-1~exp1.pgdg110+1
1010
PG_REPACK_VERSION = 1.4.8
1111
PG_AUTO_FAILOVER_VERSION = 2.0
12+
POSTGRES_HLL_VERSION = 2.17
1213
PG_VER_NUMBER=$(shell echo $(PG_VER) | cut -c3-)
1314

1415
TS_VERSION=main
@@ -30,7 +31,8 @@ DOCKER_BUILD_ARGS = --build-arg PG_VERSION=$(PG_VER_NUMBER) \
3031
--build-arg PG_AUTO_FAILOVER_VERSION=$(PG_AUTO_FAILOVER_VERSION) \
3132
--build-arg POSTGIS_MAJOR=$(POSTGIS_MAJOR) \
3233
--build-arg PG_MAJOR=$(PG_MAJOR) \
33-
--build-arg POSTGIS_VERSION=$(POSTGIS_VERSION)
34+
--build-arg POSTGIS_VERSION=$(POSTGIS_VERSION) \
35+
--build-arg POSTGRES_HLL_VERSION=$(POSTGRES_HLL_VERSION)
3436

3537
default: image
3638

bitnami/timescaledb-bitnami-entrypoint.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,9 @@
44
# the shared preload list, or else it gets overwritten.
55
if [ -z "$POSTGRESQL_SHARED_PRELOAD_LIBRARIES" ]
66
then
7-
POSTGRESQL_SHARED_PRELOAD_LIBRARIES="citus,timescaledb,zombodb,pg_repack,pgautofailover"
7+
POSTGRESQL_SHARED_PRELOAD_LIBRARIES="citus,timescaledb,zombodb,pg_repack,pgautofailover,hll"
88
else
9-
POSTGRESQL_SHARED_PRELOAD_LIBRARIES="citus,timescaledb,zombodb,pg_repack,pgautofailover,$POSTGRESQL_SHARED_PRELOAD_LIBRARIES"
9+
POSTGRESQL_SHARED_PRELOAD_LIBRARIES="citus,timescaledb,zombodb,pg_repack,pgautofailover,hll,$POSTGRESQL_SHARED_PRELOAD_LIBRARIES"
1010
fi
1111
export POSTGRESQL_SHARED_PRELOAD_LIBRARIES
1212

0 commit comments

Comments
 (0)