Unable to install Powershell module through Docker file

Hi everyone,

I’m new to Docker and this forum sk I hope that this is the right place to ask.
I’m trying to build and image of Windows Server Core 2019, with SQL server installed. In order to be able to create a DB user, I’m trying to install the dbatools module, and others as well.
The problem is that the module installation is failing due to missing Nuget version.
If I wait for the containter to be built, start Powershell and install the modules manually, it all works fine.
Can anyone please tell me what I am missing?

Thank you.