502 Bad Gateway after updating to latest version

You can check the postgres version at /var/discourse/shared/standalone/postgres_data/PG_VERSION – If you did a command line upgrade, it’s possible that it did the upgrade and you didn’t notice (but you’d have to have run the rebuild twice). If you upgraded from the web interface, you should probably go ahead and do a command line rebuild if your OS and docker are recent versions.