正在尝试为plex构建dockerfile
我是docker的新手,并以此为例介绍如何学习。我正在尝试创建一个dockerfile,它允许我在windows服务器上运行plex。在Plex论坛上创建的一篇很棒的帖子描述了如何使用powershell执行任务,因此我想看看是否可以使用这些命令创建映像 以下是我到目前为止的情况:正在尝试为plex构建dockerfile,docker,dockerfile,plex,Docker,Dockerfile,Plex,我是docker的新手,并以此为例介绍如何学习。我正在尝试创建一个dockerfile,它允许我在windows服务器上运行plex。在Plex论坛上创建的一篇很棒的帖子描述了如何使用powershell执行任务,因此我想看看是否可以使用这些命令创建映像 以下是我到目前为止的情况: FROM microsoft/windowsservercore RUN Get-ChildItem "$Env:SystemRoot\Servicing\Packages\*Media*.mum" | ForEa
FROM microsoft/windowsservercore
RUN Get-ChildItem "$Env:SystemRoot\Servicing\Packages\*Media*.mum" | ForEach-Object { (Get-Content $_) -replace 'required','no' | Set-Content $_}
RUN Add-WindowsFeature Server-Media-Foundation;
RUN Invoke-WebRequest -OutFile Plex-Media-Server-1.12.3.4973-215c28d86.exe "https://downloads.plex.tv/plex-media-server/1.12.3.4973-215c28d86/Plex-Media-Server-1.12.3.4973-215c28d86.exe" -UseBasicParsing;
RUN .\plex.exe /quiet
RUN start 'C:\Program Files (x86)\Plex\Plex Media Server\Plex Media Server.exe'
EXPOSE 32400/tcp
我已删除用于格式化的注释。
所以我有两个问题
第一:当使用docker build-t test_plex时,这似乎不运行。
我得到以下错误:
unable to prepare context: unable to evaluate symlinks in Dockerfile path: GetFileAttributesEx C:\Windows\System32\Dockerfile: The system cannot find the file specified.
第二:使用PowerShell,这一切会并行运行吗?或者有什么等待命令
任何帮助/提示都会很好,谢谢您的时间(很抱歉发了这么长的帖子)看起来您正在运行
docker build-t test\u plex.
中的C:\Windows\System32\
。移动到只有Dockerfile的空文件夹,然后再次运行该命令
是构建上下文的位置,您还可以将该位置更改为其他路径
请记住,运行
docker build-t test\u plex时,“构建上下文”或运行时所在的目录与构建相关。根据您的系统,运行该命令的位置上的所有文件都将复制到构建vm中 看起来您正在运行C:\Windows\System32\
中的docker build-t test\u plex.
。移动到只有Dockerfile的空文件夹,然后再次运行该命令
是构建上下文的位置,您还可以将该位置更改为其他路径
请记住,运行docker build-t test\u plex时,“构建上下文”或运行时所在的目录与构建相关。根据您的系统,运行该命令的位置上的所有文件都将复制到构建vm中