Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions .github/workflows/smoke-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,16 @@ jobs:
fi
if psql -c "select 1"
then
echo "Test Citus Extension"
psql -c "CREATE EXTENSION citus;"
psql -c "SELECT * FROM citus_version();"

echo "Test Citus Distributed Table"
psql -c "CREATE TABLE test_distributed_table (id serial primary key, data text);"
psql -c "SELECT create_distributed_table('test_distributed_table', 'id');"
psql -c "INSERT INTO test_distributed_table (data) VALUES ('test data');"
psql -c "SELECT * FROM test_distributed_table;"

break
fi
sleep 1
Expand Down
35 changes: 35 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -93,3 +93,38 @@ RUN apk add --no-cache --virtual .build-deps \
&& ls \
&& make \
&& make install

## Adding Citus

# Install Citus dependencies
RUN apk add --no-cache --virtual .citus-deps \
curl \
jq

# Install Citus
ARG CITUS_VERSION="11.2.0"
RUN set -ex \
&& apk add --no-cache --virtual .citus-build-deps \
gcc \
libc-dev \
make \
curl-dev \
lz4-dev \
zstd-dev \
clang \
krb5-dev \
icu-dev \
libxslt-dev \
libxml2-dev \
llvm15-dev \
&& CITUS_DOWNLOAD_URL="https://github.com/citusdata/citus/archive/refs/tags/v${CITUS_VERSION}.tar.gz" \
&& curl -L -o /tmp/citus.tar.gz "${CITUS_DOWNLOAD_URL}" \
&& tar -C /tmp -xvf /tmp/citus.tar.gz \
&& chown -R postgres:postgres /tmp/citus-${CITUS_VERSION} \
&& cd /tmp/citus-${CITUS_VERSION} \
&& PATH="/usr/local/pgsql/bin:$PATH" ./configure \
&& make \
&& make install \
&& cd ~ \
&& rm -rf /tmp/citus.tar.gz /tmp/citus-${CITUS_VERSION} \
&& apk del .citus-deps .citus-build-deps