8000 refactor: Update postgres-docker image to 15.12 by bciaraldi · Pull Request #31525 · PostHog/posthog · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

refactor: Update postgres-docker image to 15.12 #31525

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

Closed
wants to merge 5 commits into from

Conversation

bciaraldi
Copy link
Contributor

Important

👉 Stay up-to-date with PostHog coding conventions for a smoother review.

Problem

Changes

Does this work well for both Cloud and self-hosted?

How did you test this code?

Copy link
Contributor
@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

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

PR Summary

This PR updates PostgreSQL from version 12 to 15.12 across Docker Compose configurations and increases the DigitalOcean droplet size for hobby deployments.

  • Inconsistent comment in docker-compose.hobby.yml mentions pinning to Postgres 12 but uses 15.12-alpine image
  • Missing migration path/pg_upgrade process for existing hobby deployments moving from Postgres 12 to 15
  • Added docker-compose.base.yml to E2E test triggers in CI workflow for better coverage
  • Doubled DigitalOcean droplet resources to 8vCPU/16GB for hobby deployment testing
  • Breaking changes between Postgres 12 and 15 need to be addressed for self-hosted installations

💡 (1/5) You can manually trigger the bot by mentioning @greptileai in a comment!

4 file(s) reviewed, 1 comment(s)
Edit PR Review Bot Settings | Greptile

Comment on lines 16 to +17
# Pin to postgres 12 until we have a process for pg_upgrade to postgres 15 for exsisting installations
image: ${DOCKER_REGISTRY_PREFIX:-}postgres:12-alpine
image: ${DOCKER_REGISTRY_PREFIX:-}postgres:15.12-alpine
Copy link
Contributor

Choose a reason for hiding this comment

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

logic: Comment states 'Pin to postgres 12' but image is set to 15.12. Either update the comment or keep postgres 12 as indicated

Suggested change
# Pin to postgres 12 until we have a process for pg_upgrade to postgres 15 for exsisting installations
image: ${DOCKER_REGISTRY_PREFIX:-}postgres:12-alpine
image: ${DOCKER_REGISTRY_PREFIX:-}postgres:15.12-alpine
# Using postgres 15.12 for new installations
image: ${DOCKER_REGISTRY_PREFIX:-}postgres:15.12-alpine

Copy link
Contributor
github-actions bot commented Apr 23, 2025

Size Change: +81 B (0%)

Total Size: 13.7 MB

ℹ️ View Unchanged
Filename Size Change
frontend/dist/toolbar.js 13.7 MB +81 B (0%)

compressed-size-action

Comment on lines 16 to +17
# Pin to postgres 12 until we have a process for pg_upgrade to postgres 15 for exsisting installations
image: ${DOCKER_REGISTRY_PREFIX:-}postgres:12-alpine
image: ${DOCKER_REGISTRY_PREFIX:-}postgres:15.12-alpine
Copy link
Contributor

Choose a reason for hiding this comment

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

There appears to be a contradiction between the comment and the actual code change. The comment states:

Pin to postgres 12 until we have a process for pg_upgrade to postgres 15 for existing installations

However, the image is being updated to postgres:15.12-alpine. This raises concerns about backward compatibility for existing hobby installations, as PostgreSQL 15 data directories are not compatible with PostgreSQL 12.

Before proceeding with this change, it would be important to:

  1. Either update the comment to reflect the current state
  2. Or maintain PostgreSQL 12 until a proper upgrade process is implemented
  3. Or document the upgrade process if one exists

Without addressing this inconsistency, existing hobby installations may experience failures during upgrades due to PostgreSQL version incompatibility.

Suggested change
# Pin to postgres 12 until we have a process for pg_upgrade to postgres 15 for exsisting installations
image: ${DOCKER_REGISTRY_PREFIX:-}postgres:12-alpine
image: ${DOCKER_REGISTRY_PREFIX:-}postgres:15.12-alpine
# Using postgres 15 - Note: Upgrading from postgres 12 requires a data migration process
image: ${DOCKER_REGISTRY_PREFIX:-}postgres:15.12-alpine

Spotted by Diamond

Is this helpful? React 👍 or 👎 to let us know.

@bciaraldi bciaraldi marked this pull request as draft April 24, 2025 16:51
@posthog-bot
Copy link
Contributor

This PR hasn't seen activity in a week! Should it be merged, closed, or further worked on? If you want to keep it open, post a comment or remove the stale label – otherwise this will be closed in another week. If you want to permanentely keep it open, use the waiting label.

@posthog-bot
Copy link
Contributor

This PR was closed due to lack of activity. Feel free to reopen if it's still relevant.

@posthog-bot posthog-bot closed this May 9, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants
0