I wanted to add a quick additional detail to this closed topic. I experienced a similar issue on a Digital Ocean Discourse droplet I’ve had running for about 5 years with the exact same errors. I tried to upgrade from the admin interface in Discourse and it went fine until updating the Discourse app.
My only addition here is that after updating my server, for whatever reason, I still needed to run apt upgrade docker-ce to get Docker to go from v18 to v24. I then was able to run ./launcher rebuild app