I’m pretty sure that the issue is that you’ve got 16 and Discourse has the PG15 tools. You need to go into the container and switch to the PG16 tools.
The longer-term solution is to add code to your app.yml
that will upgrade the PG tools when you build a new container.
I did that for someone a while back but I’m not working for them now and can’t find my code.
You’d google “how to upgrade to PG16” and then do that inside the container. Then you’d add stuff to the app.yml
to do it when it rebuilds.