Repository navigation
Backport #35445 to 2.0: Drop PostgreSQL server packages from the operator images - #37615
Merged
Merged
Conversation
- Ports the operator image part of #35445 to 2.0: only libpq-dev comes from pgdg, and postgresql and postgresql-contrib leave the Debian package list - The server packages were all that kept libxml2 installed on 2.0, so libxml2 and shared-mime-info are purged again as on main (#35940), with libxml2 back in the ldd check - libpq-dev stays for the psycopg2 source build and keeps libpq5 installed - The Airflow images are left as they are, since they install libxml2 directly
mohittilala
requested review from
akashverma0786
and removed request for
a team
November 12, 2026 03:49
Code Review ✅ Approved 🟡 Medium riskRemoving PostgreSQL packages and purging libxml2 from operator images changes runtime dependencies and could break workloads that implicitly rely on them. Drops the PostgreSQL server packages and keeps only VerificationRules No rules evaluated Functional validation Not enabledAuto-approval Not enabledFor more verification details, comment OptionsDisplay: compact → Showing compact verification results. Comment with these commands to change the behavior for this request:
Was this helpful? React with 👍 / 👎 | Powered by Gitar — free for open source |
ulixius9
approved these changes
Nov 12, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Describe your changes:
Backports the operator image part of #35445 to
2.0, and with it the libxml2 purge that #36052 had to leave out of the2.0backport of #35940.The
2.0operator images still install the PostgreSQL server packages (postgresql,postgresql-contrib, and from pgdgpostgresql-client,postgresql-common,postgresql,postgresql-contrib). Nothing in the image runs a PostgreSQL server or the client tools, and those packages are the only reason libxml2 could not be purged on2.0, as the comment #36052 added says. This PR:libpq-devfrom pgdg, asmaindoes, and dropspostgresqlandpostgresql-contribfrom the Debian package list.libpq-devstays, sincepip install psycopg2still compiles against it, and it keepslibpq5installed.libxml2 shared-mime-infoback to thedpkg --purgelist andlibxml2back to thelddcheck, withmain's comment.Only
ingestion/operators/docker/DockerfileandDockerfile.cichange, and the two diffs are identical. #35445 also removed the server from the Airflow images (ingestion/DockerfileandDockerfile.ci), bumpedaiobotocoreandboto3and swapped the Elasticsearch client. None of that is needed here, and those images install libxml2 directly anyway, so they are left as they are.Type of change:
High-level design:
N/A, small change.
Tests:
Use cases covered
2.0operator image builds, purges libxml2 and still imports its native extensions.Manual testing performed
ingestion/operators/docker/Dockerfile.ciwith--build-arg INGESTION_DEPENDENCY=slim, as the nightly does, for linux/arm64 on Docker Desktop. The build passed, including the image's owndpkg --purge, native import andlddchecks.libxml2,shared-mime-info,postgresql*orlibllvm*packages, nolibxml2.so*on disk, and nopsqlorpg_dump.libpq5andlibpq-devare installed,psycopg2imports, andlxmlworks on its bundled libxml2.git grepofingestion/srcandingestion/operatorsfinds nothing that runspsql,pg_dump,pg_restore,pg_ctlorinitdb.Not run: the plain
Dockerfile, whose diff is identical, and an amd64 build.Checklist:
REVIEW.mdand found nothing to fix.main's existing behavior to2.0.