Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature request: cargo pgx init --pg12=https://ftp.postgresql.org/pub/source/v12.6/postgresql-12.6.tar.bz2 #149

Open
W1M0R opened this issue May 17, 2021 · 1 comment · May be fixed by #1605
Labels
good first issue Good for newcomers

Comments

@W1M0R
Copy link

W1M0R commented May 17, 2021

It would be very helpful for Nix-based environments (or for reproducible builds in general) to specify an exact version of postgres to use during the cargo pgx init phase.

I have tried using a nix-shell with cargo pgx init --pg12=${postgresql_12}/bin/pg_config, however, since the nix store paths are not writable, this doesn't help much (e.g. pgx run, pgx install and pgx package will not work). I have also tried copying the nix postgresql_12 to a local writable directory, then using that directory during pgx init, however, the pg_config of that writable copy will still produce absolute nix store path outputs (nix has a very opinionated method to guarantee reproducible builds). Using pgx init --pg12=download will not produce reproducible builds in a clean CI environment.

Also see comment #105 (comment) by @Hoverbear.

Please consider allowing init to accept a specific download url (or a part of the url), or alternatively, to accept a full version number.

Examples:

cargo pgx init --pg12=https://ftp.postgresql.org/pub/source/v12.6/postgresql-12.6.tar.bz2
cargo pgx init --pg12=12.6
@Hoverbear
Copy link
Contributor

Hey @W1M0R , I think this is a good feature suggestion!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers
Projects
None yet
3 participants