ANXS / postgresql

Fairly full featured Ansible role for Postgresql.
http://anxs.io/
MIT License
848 stars 571 forks source link

support PostgreSQL 16 #564

Closed conscribtor closed 5 months ago

conscribtor commented 6 months ago

resolves #565

MrMegaNova commented 6 months ago

Thanks for your work, can you please reopen this PR to pull on dev branch ?

conscribtor commented 6 months ago

Thanks for your work, can you please reopen this PR to pull on dev branch ?

I've changed the base branch to development. I hope this has the intended result, I'm more familiar with GitLab ;-). I can additionally rebase my fork on dev if necessary.

MrMegaNova commented 6 months ago

Hi thanks for your quick reply I haven't seen the reply notification, sorry for the delay.

conscribtor commented 6 months ago

@MrMegaNova

Hi thanks for your quick reply I haven't seen the reply notification, sorry for the delay.

No problem. It was that time of the year anyway. 🥳 Thank you for running the CI. It seems that due to the issue raised in #566, it can't succeed. Also, it seems that they have moved the location of the GPG for yum: https://yum.postgresql.org/news/pgdg-rpm-repo-gpg-key-update/.

I'll try to fix this, but I might have to extend the scope to include the removal of PG11 to make it work. Would that be okay?

I'll be working in the conditional defaults as discussed in https://github.com/ANXS/postgresql/issues/565#issuecomment-1883229691.

MrMegaNova commented 5 months ago

Thanks for your proposal, we want to drop testing on postgresql 11 on every distro. I will create a new PR myself to to do it, you will be able to import my commit to fix this issue.

conscribtor commented 5 months ago

I've noticed that on my Ubuntu 22.04 a few variables are not set due to Debian_22.yml not containing them. Due to the missing postgresql_service_name the Reload PostgreSQL configuration task will error out. This is skipped in the tests and thus won't be detected.

I hope it's okay that I included this in this MR, since without it I'm unable to test my changes. Due to the missing postgresql_bin_directory the tasks that add database extensions won't work on Ubuntu 22.04 either. Shall I add them?

conscribtor commented 5 months ago

Also, it seems that they have moved the location of the GPG for yum: https://yum.postgresql.org/news/pgdg-rpm-repo-gpg-key-update/.

I've pushed bf99ff3 to address this and successfully smoke tested with the test playbook on Rocky Linux 9, Debian 12, Ubuntu 22.04 and CentOS 8.

MrMegaNova commented 5 months ago

Hi @conscribtor , You've done right, I've encounter the same problem with gpg key for pgdg during testing. I've used your commit to fix this on my MR: #567 I've done some work removing testing on pg 11 and cleaning compatibility matrix. I'm ready to add testing on pg 16 if you haven't already done that on your MR.

I'm gonna merge #567, then I will review one more time your MR and merge it @tsoulabail If you have some time to double review this PR and approve it, it would be nice

MrMegaNova commented 5 months ago

About the conflict, you''ve done right using :no_entry: instead of :interrobang: on pg 10 & 11 So you can resolve this way. I also think about removing old versions like pg 10 and Ubuntu 16.04, 18.04, CentOS 7.x and Fedora 37 so if you think the same way, you can do that too.

conscribtor commented 5 months ago

I've merged the current development branch into this PR's branch.

I think that we should leave only the last EOL PostgreSQL version in the table. The user can then safely infer that all versions older than that are also EOL.

I've included your proposed removal of EOL operating systems, since I think that repositories and GPG keys may become unavailable at any moment, which will lead to confusion if it is marked as working in the matrix.

I've also removed Debian 10, since it is now under LTS support (comparable to Ubuntu's 18.04 Expanded Security Maintenance that ends in 2028).

conscribtor commented 5 months ago

@MrMegaNova

I'm ready to add testing on pg 16 if you haven't already done that on your MR.

I'd be happy to leave that to you. I'm unexperienced with Molecule tests.

MrMegaNova commented 5 months ago

Good job ! I will add pg16 testing before merging

gclough commented 3 months ago

@conscribtor, I just wanted to say thanks for helping out on this.