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

Update Mattermost to v10 and PostgreSQL to v17 #91

Open
wants to merge 4 commits into
base: main
Choose a base branch
from
Open

Conversation

stephdl
Copy link
Contributor

@stephdl stephdl commented Feb 5, 2025

Upgrade the Mattermost version to 10.4.1 and PostgreSQL to v17 in the build images script.

NethServer/dev#7245

@stephdl stephdl marked this pull request as draft February 5, 2025 08:53
@stephdl stephdl force-pushed the sdl-7245 branch 2 times, most recently from 17faa74 to ebb7140 Compare February 5, 2025 11:23
@stephdl stephdl marked this pull request as ready for review February 5, 2025 12:56
Copy link
Member

@DavidePrincipi DavidePrincipi left a comment

Choose a reason for hiding this comment

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

As alternative to full DB dump, upgrade PG from 13 to 17 has an helper from the PG official Docker Library image maintainer: https://github.com/tianon/docker-postgres-upgrade.

It seems pg_upgrade is way faster than a full dump/restore.

@stephdl
Copy link
Contributor Author

stephdl commented Feb 6, 2025

I referenced to this https://www.postgresql.org/docs/13/upgrading.html

I used something that we know it works because we use it for restoration, but I can test

@stephdl
Copy link
Contributor Author

stephdl commented Feb 6, 2025

well not possible @DavidePrincipi

  • podman run --rm -v postgres-data:/var/lib/postgresql/data:z -e PGDATAOLD=/var/lib/postgresql/data -e PGDATANEW=/var/lib/postgresql/17/data tianon/postgres-upgrade:13-to-17 pg_upgrade --link
    connection to server on socket "/var/lib/postgresql/.s.PGSQL.50432" failed: FATAL: role "postgres" does not exist
  • podman run --rm -v postgres-data:/var/lib/postgresql/data:z -e PGDATAOLD=/var/lib/postgresql/data -e PGDATANEW=/var/lib/postgresql/17/data tianon/postgres-upgrade:13-to-17 pg_upgrade -U mattuser --link
    connection to server on socket "/var/lib/postgresql/.s.PGSQL.50432" failed: FATAL: role "mattuser" does not exist

see tianon/docker-postgres-upgrade#100 (comment) and this part of code
https://github.com/tianon/docker-postgres-upgrade/blob/404a72189ae9581adf5f5241589be13af2051095/13-to-17/Dockerfile#L26
https://github.com/tianon/docker-postgres-upgrade/blob/404a72189ae9581adf5f5241589be13af2051095/13-to-17/docker-upgrade#L13

we expect a postgres user and we use mattuser, so

  • we can create a fork to migrate
  • wait the feature is accepted
  • use the backup/restore way

thoughts

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.

2 participants