Skip to content
This repository has been archived by the owner on Jan 30, 2024. It is now read-only.

Add posgresql extension debversion to pulp db #166

Closed
wants to merge 1 commit into from

Conversation

mdellweg
Copy link
Member

No description provided.

@@ -2,6 +2,7 @@
pulp_preq_packages:
- python3
- python3-venv
- postgresql-11-debversion
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This package needs packaging on the RPM side.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mdellweg I am a Fedora packager. I can help you with this.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

libapt-pkg5.0 would be a new dependency.

We can use the mageia 4.0 RPMs as a starting point:
https://mageia.pkgs.org/cauldron/mageia-core-release-i586/libapt-pkg4-0.5.15lorg3.94-33.mga8.i586.rpm.html

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe i have seen this package. Is mageia not a direct descendent of mandrake? I think, they ported apt to use rpm, and consequently patched all the debian package specific stuff away.
Therefore i was persuing another way. I looked for the single function we need, and patched that one into the postgres-extension:
https://github.com/ATIX-AG/foreman-packaging/blob/add_postgresql_debversion/packages/katello/postgresql-debversion/0001-Copy-relevant-code-from-apt-pkg-to-ease-packaging.patch
This drops the dependency on libapt completely.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Started an effort to write a spec file for this:
theforeman/foreman-packaging#4540

Still i am not really sure that is the place to make it available for all pulp users.

@mdellweg
Copy link
Member Author

In order to make the extension available to the test_database, i needed to run:

# /usr/local/lib/pulp/bin/ansible localhost --become --become-user postgres -m postgresql_ext -a "db=template1 ext=debversion"

But i don't feel like we want to activate this extension on the global template for all future databases.

Copy link
Member

@mikedep333 mikedep333 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In order to make the extension available to the test_database, i needed to run:

# /usr/local/lib/pulp/bin/ansible localhost --become --become-user postgres -m postgresql_ext -a "db=template1 ext=debversion"

But i don't feel like we want to activate this extension on the global template for all future databases.

Similar to how we introduced the prereq_role sub-variable for pulp-rpm, we could do something similar for postgres extensions.

@mdellweg
Copy link
Member Author

Maybe it's even better to use something like https://github.com/dimitri/pgextwlist .
But that can still go into a prereq_role.

@pulpbot
Copy link
Member

pulpbot commented Jun 8, 2020

WARNING!!! This PR is not attached to an issue. In most cases this is not advisable. Please see our PR docs for more information about how to attach this PR to an issue.

@dkliban
Copy link
Member

dkliban commented Jul 1, 2020

Let's reopen when we start working on this again.

@dkliban dkliban closed this Jul 1, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants