Skip to content

Commit

Permalink
Updates repo with PG 16 changes (#345)
Browse files Browse the repository at this point in the history
* Adds pg 16

* Fixes version problem

* Fixes alpine version

* Updates tools tags
  • Loading branch information
gurkanindibay authored Sep 21, 2023
1 parent 22eb14b commit 5429707
Show file tree
Hide file tree
Showing 9 changed files with 60 additions and 17 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/publish_docker_images_cron.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ jobs:
uses: actions/checkout@v3

- name: Clone tools branch
run: git clone -b v0.8.27 --depth=1 https://github.com/citusdata/tools.git tools
run: git clone -b v0.8.30 --depth=1 https://github.com/citusdata/tools.git tools

- name: Install package dependencies
run: sudo apt-get update && sudo apt install libcurl4-openssl-dev libssl-dev python3-testresources
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/publish_docker_images_on_manual.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ jobs:
uses: actions/checkout@v3

- name: Clone tools branch
run: git clone -b v0.8.27 --depth=1 https://github.com/citusdata/tools.git tools
run: git clone -b v0.8.30 --depth=1 https://github.com/citusdata/tools.git tools

- name: Install package dependencies
run: sudo apt-get update && sudo apt install libcurl4-openssl-dev libssl-dev python3-testresources
Expand Down
3 changes: 2 additions & 1 deletion .github/workflows/publish_docker_images_on_push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,14 +17,15 @@ jobs:
image_type:
- latest
- alpine
- postgres_15
- postgres_14
- nightly
steps:
- name: Checkout repository
uses: actions/checkout@v3

- name: Clone tools branch
run: git clone -b v0.8.24 --depth=1 https://github.com/citusdata/tools.git tools
run: git clone -b v0.8.30 --depth=1 https://github.com/citusdata/tools.git tools

- name: Install package dependencies
run: sudo apt-get update && sudo apt install libcurl4-openssl-dev libssl-dev python3-testresources
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/publish_docker_images_on_tag.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ jobs:
ref: master

- name: Clone tools branch
run: git clone -b v0.8.27 --depth=1 https://github.com/citusdata/tools.git tools
run: git clone -b v0.8.30 --depth=1 https://github.com/citusdata/tools.git tools

- name: Install package dependencies
run: sudo apt-get update && sudo apt install libcurl4-openssl-dev libssl-dev python3-testresources
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/update_version.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ jobs:
run: sudo apt-get update && sudo apt install libcurl4-openssl-dev libssl-dev python3-testresources

- name: Clone tools branch
run: git clone -b v0.8.27 --depth=1 https://github.com/citusdata/tools.git tools
run: git clone -b v0.8.30 --depth=1 https://github.com/citusdata/tools.git tools

- name: Set git name and email
run: |
Expand Down
10 changes: 5 additions & 5 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# This file is auto generated from it's template,
# see citusdata/tools/packaging_automation/templates/docker/latest/latest.tmpl.dockerfile.
FROM postgres:15.3
ARG VERSION=12.0.0
FROM postgres:16.0
ARG VERSION=12.1.0
LABEL maintainer="Citus Data https://citusdata.com" \
org.label-schema.name="Citus" \
org.label-schema.description="Scalable PostgreSQL for multi-tenant and real-time workloads" \
Expand All @@ -19,9 +19,9 @@ RUN apt-get update \
ca-certificates \
curl \
&& curl -s https://install.citusdata.com/community/deb.sh | bash \
&& apt-get install -y postgresql-$PG_MAJOR-citus-12.0=$CITUS_VERSION \
postgresql-$PG_MAJOR-hll=2.17.citus-1 \
postgresql-$PG_MAJOR-topn=2.5.0.citus-1 \
&& apt-get install -y postgresql-$PG_MAJOR-citus-12.1=$CITUS_VERSION \
postgresql-$PG_MAJOR-hll=2.18.citus-1 \
postgresql-$PG_MAJOR-topn=2.6.0.citus-1 \
&& apt-get purge -y --auto-remove curl \
&& rm -rf /var/lib/apt/lists/*

Expand Down
4 changes: 2 additions & 2 deletions alpine/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# This file is auto generated from it's template,
# see citusdata/tools/packaging_automation/templates/docker/alpine/alpine.tmpl.dockerfile.
FROM postgres:15.3-alpine
ARG VERSION=12.0.0
FROM postgres:16.0-alpine
ARG VERSION=12.1.0
LABEL maintainer="Citus Data https://citusdata.com" \
org.label-schema.name="Citus" \
org.label-schema.description="Scalable PostgreSQL for multi-tenant and real-time workloads" \
Expand Down
10 changes: 5 additions & 5 deletions postgres-14/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# This file is auto generated from it's template,
# see citusdata/tools/packaging_automation/templates/docker/postgres-14/postgres-14.tmpl.dockerfile.
FROM postgres:14.8
ARG VERSION=12.0.0
FROM postgres:14.9
ARG VERSION=12.1.0
LABEL maintainer="Citus Data https://citusdata.com" \
org.label-schema.name="Citus" \
org.label-schema.description="Scalable PostgreSQL for multi-tenant and real-time workloads" \
Expand All @@ -19,9 +19,9 @@ RUN apt-get update \
ca-certificates \
curl \
&& curl -s https://install.citusdata.com/community/deb.sh | bash \
&& apt-get install -y postgresql-$PG_MAJOR-citus-12.0=$CITUS_VERSION \
postgresql-$PG_MAJOR-hll=2.17.citus-1 \
postgresql-$PG_MAJOR-topn=2.5.0.citus-1 \
&& apt-get install -y postgresql-$PG_MAJOR-citus-12.1=$CITUS_VERSION \
postgresql-$PG_MAJOR-hll=2.18.citus-1 \
postgresql-$PG_MAJOR-topn=2.6.0.citus-1 \
&& apt-get purge -y --auto-remove curl \
&& rm -rf /var/lib/apt/lists/*

Expand Down
42 changes: 42 additions & 0 deletions postgres-15/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
# This file is auto generated from it's template,
# see citusdata/tools/packaging_automation/templates/docker/latest/latest.tmpl.dockerfile.
FROM postgres:15.4
ARG VERSION=12.1.0
LABEL maintainer="Citus Data https://citusdata.com" \
org.label-schema.name="Citus" \
org.label-schema.description="Scalable PostgreSQL for multi-tenant and real-time workloads" \
org.label-schema.url="https://www.citusdata.com" \
org.label-schema.vcs-url="https://github.com/citusdata/citus" \
org.label-schema.vendor="Citus Data, Inc." \
org.label-schema.version=${VERSION} \
org.label-schema.schema-version="1.0"

ENV CITUS_VERSION ${VERSION}.citus-1

# install Citus
RUN apt-get update \
&& apt-get install -y --no-install-recommends \
ca-certificates \
curl \
&& curl -s https://install.citusdata.com/community/deb.sh | bash \
&& apt-get install -y postgresql-$PG_MAJOR-citus-12.1=$CITUS_VERSION \
postgresql-$PG_MAJOR-hll=2.18.citus-1 \
postgresql-$PG_MAJOR-topn=2.6.0.citus-1 \
&& apt-get purge -y --auto-remove curl \
&& rm -rf /var/lib/apt/lists/*

# add citus to default PostgreSQL config
RUN echo "shared_preload_libraries='citus'" >> /usr/share/postgresql/postgresql.conf.sample

# add scripts to run after initdb
COPY 001-create-citus-extension.sql /docker-entrypoint-initdb.d/

# add health check script
COPY pg_healthcheck wait-for-manager.sh /
RUN chmod +x /wait-for-manager.sh

# entry point unsets PGPASSWORD, but we need it to connect to workers
# https://github.com/docker-library/postgres/blob/33bccfcaddd0679f55ee1028c012d26cd196537d/12/docker-entrypoint.sh#L303
RUN sed "/unset PGPASSWORD/d" -i /usr/local/bin/docker-entrypoint.sh

HEALTHCHECK --interval=4s --start-period=6s CMD ./pg_healthcheck

0 comments on commit 5429707

Please sign in to comment.