How to upgrade if `/var/discourse` has only `shared` and is not git repo

You should do a clean install on a new VM, make a backup, and restore it to the new installation.

If you don’t like that answer, then you should get whoever set that thing up to come and fix it.