Visual Studio publish error code 0x80070005 -- Bootstrap license

I'm having the same exact issue, looks like the issue is caused by VS 2022. I think it is taking a file that has no extension named License and mistaking it for a folder. I was able to fix the issue by deleting the License file and the folder that was created on my web server by VS 2022 on deploy.


Got it fixed thanks to MS support. Somehow server folder wwwroot structure had been corrupted.