postgis/postgis:17-3.5 apt-get update fails: "E: The repository 'http://apt.postgresql.org/pub/repos/apt bullseye-pgdg Release' does not have a Release file"
Fix: move to a current tag (postgis/postgis:17-3.6 or 17-3.7, both rebuilt in late 2026), or, if you must stay on 17-3.5, drop the dead PGDG source before installing anything: RUN rm -f /etc/apt/sources.list.d/pgdg.list && apt-get update && apt-get install -y --no-install-recommends gdal-bin python3-pip ....
Cause: the 17-3.5 image is built on Debian bullseye, and its last push was in August 2026. http://apt.postgresql.org/pub/repos/apt/dists/bullseye-pgdg/Release now returns 404, so any apt-get update in a derived Containerfile fails before installing extra packages (GDAL, Python, curl). After removing pgdg.list, the same build also got Err: lines for bullseye-security packages (libc6 2.31-13+deb11u14, python3.9 3.9.2-1+deb11u7). The workaround was sed -i '/security/d' /etc/apt/sources.list, which is acceptable for a throwaway dev image but means no security updates. Prefer a newer base tag.
Other things the old base gives you: Python 3.9 and bullseye's GDAL. python3-geopandas/python3-matplotlib from apt pull in hundreds of packages (gcc, tk, numba), so install those with pip only if you need them, or keep the tile/analysis tooling in a separate image.
Verify: podman run --rm postgis/postgis:17-3.5 cat /etc/os-release shows bullseye, and podman run --rm postgis/postgis:17-3.5 bash -c 'apt-get update' reproduces the Release-file error.