Re: RFC: Additional Directory for Extensions - Mailing list pgsql-hackers

From Gabriele Bartolini
Subject Re: RFC: Additional Directory for Extensions
Date
Msg-id CA+VUV5oWkMVvtNB0BG2CM8SrmOkeW6fEtXGehbniHqR9MhMzVw@mail.gmail.com
Whole thread Raw
In response to Re: RFC: Additional Directory for Extensions  ("David E. Wheeler" <david@justatheory.com>)
Responses Re: RFC: Additional Directory for Extensions
List pgsql-hackers
Hi everyone,

Apologies for only starting to look into this now. Thanks, David, for pushing this forward.

I want to emphasize the importance of this patch for the broader adoption of extensions in immutable container environments, such as those used by the CloudNativePG operator in Kubernetes.

To provide some context, one of the key principles of CloudNativePG is that containers, once started, cannot be modified—this includes the installation of Postgres extensions and their libraries. This restriction prevents us from adding extensions on the fly, requiring them to be included in the main PostgreSQL operand image. As a result, users who need specific extensions must build custom images through automated pipelines (see: https://cloudnative-pg.io/blog/creating-container-images/).

We’ve been considering ways to improve this process for some time. The direction we're exploring involves mounting an ephemeral volume that contains the necessary extensions (namely $sharedir and $pkglibdir from pg_config). These volumes would be created and populated with the required extensions when the container starts and destroyed when it shuts down. To make this work, each extension must be independently packaged as a container image containing the appropriate files for a specific extension version, tailored to the architecture, distribution, OS version, and Postgres version.

I’m committed to thoroughly reviewing this patch, testing it with CloudNativePG and a few extensions, and providing feedback as soon as possible.

Best,
Gabriele

On Mon, 8 Jul 2024 at 18:02, David E. Wheeler <david@justatheory.com> wrote:
On Jun 25, 2024, at 18:31, David E. Wheeler <david@justatheory.com> wrote:

> For those who prefer a GitHub patch review experience, see this PR:
>
https://github.com/theory/postgres/pull/3/files

Rebased and restored PGC_SUSET in the attached v5 patch, plus noted the required privileges in the docs.

Best,

David





--
Gabriele Bartolini
Vice President, Cloud Native at EDB

pgsql-hackers by date:

Previous
From: Kirill Reshke
Date:
Subject: Re: Index AM API cleanup
Next
From: Mark Dilger
Date:
Subject: Re: Index AM API cleanup