Upgrading 2.7 to 3.1 failing: "hotlinked_media_status" already exists

Run that command (from outside the container!) and rebuild again.