Just posting this in case anyone else has this issue.
For me the .net runtime is missing. I installed it using snap on ubuntu.
.net 8 runtime
sudo snap install dotnet-runtime-80
.net 9 runtime
sudo snap instlal dotnet-runtime-90
list of runtimes to install
https://learn.microsoft.com/en-us/dotnet/core/install/linux-snap-runtime