The thing that got the site back up, after the data container was gone, was to edit data.yml and change the template to the postgres13 templet and then rebuild the data container, then it was possible to start up the data container, destroy and start the web_only container (it won’t connect to a different data container than the one it found when it was created). Then the site was back up and running.
I’m pretty sure that if I’d retried the database upgrade it would have worked, but just to be safe, I made a fresh database backup, moved him to a new droplet, restored the database, and he’s back up and running.