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

Add PostgreSQL apt repo and signing key for installing specific versions of Postgres for debian based distros #251

Open
wants to merge 8 commits into
base: master
Choose a base branch
from

Conversation

Souldiv
Copy link

@Souldiv Souldiv commented Oct 11, 2023

Changes

Included tasks for adding PostgreSQL apt repo and signing key

Reason for changes

Certain applications have need for specific versions of postgresql. The default packages variables postgres_packages even when initialized to something like postgresql-15 and postgresql-client-15 are not recognized by apt without adding the repo. Hence, it would be helpful for debian based systems to include the repo such that we can install these packages.

Installing the default packages postgresql and postgresql-contrib installs the latest version of postgres for the particular distribution.

I have tested the above code on an Ubuntu 22.04 Live Server VM. Currently without the above changes, installing the packages via apt only installs the latest version which as of writing this PR is postgres-16. With the changes I am able to install the particular version of postgres on the server.

Please let me know if there are any further changes that I might need to make.

fixes #242

@Souldiv
Copy link
Author

Souldiv commented Oct 11, 2023

Looks like CI is failing because of the issue mentioned earlier.

Installing the default packages postgresql and postgresql-contrib installs the latest version of postgres for the particular distribution.

by default the var postgresql_packages holds packages that install the latest version which means that the version postgresql_version is different hence why it doesn't find the directory at check if postgresql database is initialized task tasks/initialize.yml

@Souldiv Souldiv changed the title Modified tasks/setup-Debian.yml Add PostgreSQL apt repo and signing key for installing specific versions of Postgres for debian based distros Oct 11, 2023
Copy link

github-actions bot commented Mar 1, 2024

This pr has been marked 'stale' due to lack of recent activity. If there is no further activity, the issue will be closed in another 30 days. Thank you for your contribution!

Please read this blog post to see the reasons why I mark issues as stale.

@github-actions github-actions bot added the stale label Mar 1, 2024
@github-actions github-actions bot removed the stale label Apr 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

On Ubuntu 22 default version of postgresql package is 15
1 participant