Packaging request: pglinter (PostgreSQL linting extension, Rust/pgrx)
Packaging request: pglinter (PostgreSQL linting extension, Rust/pgrx)
От:
Pierre-Marie Petit <pierremariepetit@gmail.com>
Дата:
Hello,
I am the maintainer of pglinter, a PostgreSQL extension that analyzes a database for potential issues, performance problems and best practice violations (missing primary keys, unindexed foreign keys, redundant indexes, insecure public schema, and so on), and reports them as text or as SARIF.
I would like to ask whether pglinter could be packaged in apt.postgresql.org.
Repository: https://github.com/pmpetit/pglinter
Latest release: 2.0.0
License: Apache-2.0
Language: Rust, built with pgrx 0.18.0
PostgreSQL versions supported: 14, 15, 16, 17, 18
Architectures built and tested in our CI: amd64, arm64
Runtime dependencies: none beyond PostgreSQL itself, no shared_preload_libraries needed
I have added a debian directory to the repository with:
one binary package per major version: postgresql-NN-pglinter
rules that runs cargo pgrx package against each /usr/lib/postgresql/NN/bin/pg_config
an offline build against vendored crates (cargo vendor, pinned by Cargo.lock), so no network access is needed during the build
I have a few questions about how this fits PGDG:
Is building Rust/pgrx extensions in the PGDG build environment supported, given that cargo-pgrx is not packaged in Debian? Is there a preferred way to provide it?
Do you prefer the vendored crates shipped in the orig tarball, or a different approach?
Are there conventions I should follow first, such as debian/control.in with pg_buildext, a debian/pgversions file, or autopkgtest via pg_buildext installcheck?
The motivation is to make pglinter available as a CloudNativePG extension image. Their contribution guidelines require extensions to be installable from Debian or PGDG packages.
I am happy to adapt the packaging to your requirements and to maintain it going forward.
Thank you for your time,
Pierre-Marie Petit
https://github.com/pmpetit/pglinter
Re: Packaging request: pglinter (PostgreSQL linting extension, Rust/pgrx)
От:
Christoph Berg <myon@debian.org>
Дата:
Re: Pierre-Marie Petit > Is building Rust/pgrx extensions in the PGDG build environment supported, > given that cargo-pgrx is not packaged in Debian? Is there a preferred way > to provide it? Hi, we started working on pgrx in spring, but then lost steam because rust is complex and the tooling around packaging it is still somewhat in flux (pgrx is a multi-crate workspace (there are lots of words with weird meanings in this ecosystem) and debcargo doesn't understand that yet). We still want to do that. > Do you prefer the vendored crates shipped in the orig tarball, or a > different approach? I don't have an answer to that yet. > Are there conventions I should follow first, such as debian/control.in with > pg_buildext, a debian/pgversions file, or autopkgtest via pg_buildext > installcheck? That all sounds like a good idea, yes. Christoph