I noticed that I would have to apply packages with DISM on a 2016 nano server container.
I have downloaded and saved the Microsoft-NanoServer-Defender-Package cab files to my docker host (2016 Base Server).
I have also copied them over to my image via my Dockerfile, and I attempt to install with DISM with the following commands:
RUN Dism.exe /online /Add-Package /PackagePath:c:\Microsoft-NanoServer-Defender-Package__10-0-14393-0.cab /Quiet &
RUN Dism.exe /online /Add-Package /PackagePath:c:\Microsoft-NanoServer-Defender-Package_en-us_10-0-14393-0.cab /Quiet &
Everything seems to install fine until I launch a container with this image and open powershell in an interactive mode.
I cant seem to use any of the defender commands or verify that its running:
PS C:> Get-MpComputerStatus
Get-MpComputerStatus : The term 'Get-MpComputerStatus' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again.
At line:1 char:1
- Get-MpComputerStatus
-
+ CategoryInfo : ObjectNotFound: (Get-MpComputerStatus:String) [], CommandNotFoundException
+ FullyQualifiedErrorId : CommandNotFoundException
Am I not installing this correctly?
Started with these commands:
https://www.ntweekly.com/2016/10/19/install-windows-defender-antivirus-on-windows-nano-server-2016/
Until I realized that installation required DISM.exe.