小编And*_*eas的帖子

无法在 Docker 映像中安装 Windows 功能 NET-Framework-Features

我正在尝试从使用 .NET 3.5 的本地构建环境中创建一个 docker 映像。我尝试启用该功能但收到错误。

这是我用于重现问题的最小化 docker 文件:

FROM mcr.microsoft.com/dotnet/framework/sdk
RUN powershell "Install-WindowsFeature -Name NET-Framework-Features -Verbose"
Run Code Online (Sandbox Code Playgroud)

这是输出:

Sending build context to Docker daemon  72.74MB
Step 1/2 : FROM mcr.microsoft.com/dotnet/framework/sdk
 ---> 88afad8be364
Step 2/2 : RUN powershell "Install-WindowsFeature -Name NET-Framework-Features -Verbose"
 ---> Running in 0a377584126e
VERBOSE: Installation started...
VERBOSE: Continue with installation?
VERBOSE: Prerequisite processing started...
VERBOSE: Prerequisite processing succeeded.
Install-WindowsFeature : The request to add or remove features on the
specified server failed.
Installation of one or more roles, …
Run Code Online (Sandbox Code Playgroud)

windows .net-3.5 .net-framework docker

5
推荐指数
1
解决办法
6889
查看次数

标签 统计

.net-3.5 ×1

.net-framework ×1

docker ×1

windows ×1