- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
我一直在寻找答案的最后一天,但到目前为止我还没有找到答案。
到目前为止,我的程序只是一个新的默认dotnet new reactredux
命令。
我制作了这样的Dockerfile,当我在计算机上进行构建并运行时,它可以正常工作。
FROM microsoft/aspnetcore-build AS build
WORKDIR /app
COPY . .
RUN dotnet restore
RUN dotnet publish --output /output --configuration Release
FROM microsoft/aspnetcore-build
WORKDIR /app
COPY --from=build /output .
ENTRYPOINT [ "dotnet", "Docker.dll" ]
FROM
获取其他Docker镜像,并且该Dockerfile是一个多阶段Dockerfile,其中一个
FROM
用于帮助本地构建和使用,另一个用于帮助运行时。
FROM
上取消了-build。
Warn: Microsoft.AspNetCore.DataProtection.KeyManagement.XmlKeyManager[35]
No XML encryptor configured. Key {eeadaec5-0627-4e6e-bdea-4747bb873ba0} may be persisted to storage in unencrypted form.
Hosting environment: Production
Content root path: /app
Now listening on: http://[::]:80
Application started. Press Ctrl+C to shut down.
fail: Microsoft.AspNetCore.Diagnostics.ExceptionHandlerMiddleware[0]
An unhandled exception has occurred: Failed to start Node process. To resolve this:.
[1] Ensure that Node.js is installed and can be found in one of the PATH directories.
Current PATH enviroment variable is: /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
Make sure the Node executable is in one of those directories, or update your PATH.
[2] See the InnerException for further details of the cause.
System.InvalidOperationException: Failed to start Node process. To resolve this:.
[1] Ensure that Node.js is installed and can be found in one of the PATH directories.
Current PATH enviroment variable is: /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
Make sure the Node executable is in one of those directories, or update your PATH.
[2] See the InnerException for further details of the cause. ---> System.ComponentModel.Win32Exception: No such file or directory
at System.Diagnostics.Process.ResolvePath(String filename)
at System.Diagnostics.Process.StartCore(ProcessStartInfo startInfo)
at System.Diagnostics.Process.Start()
at System.Diagnostics.Process.Start(ProcessStartInfo startInfo)
at Microsoft.AspNetCore.NodeServices.HostingModels.OutOfProcessNodeInstance.LaunchNodeProcess(ProcessStartInfo startInfo)
--- End of inner exception stack trace ---
at Microsoft.AspNetCore.NodeServices.HostingModels.OutOfProcessNodeInstance.LaunchNodeProcess(ProcessStartInfo startInfo)
at Microsoft.AspNetCore.NodeServices.HostingModels.OutOfProcessNodeInstance..ctor(String entryPointScript, String projectPath, String[] watchFileExtensions, String commandLineArguments, CancellationToken applicationStoppingToken, ILogger nodeOutputLogger, IDictionary`2 environmentVars, Int32 invocationTimeoutMilliseconds, Boolean launchWithDebugging, Int32 debuggingPort)
at Microsoft.AspNetCore.NodeServices.HostingModels.HttpNodeInstance..ctor(NodeServicesOptions options, Int32 port)
at Microsoft.AspNetCore.NodeServices.HostingModels.NodeServicesOptionsExtensions.<>c__DisplayClass0_0.<UseHttpHosting>b__0()
at Microsoft.AspNetCore.NodeServices.NodeServicesImpl.CreateNewNodeInstance()
at Microsoft.AspNetCore.NodeServices.NodeServicesImpl.GetOrCreateCurrentNodeInstance()
at Microsoft.AspNetCore.NodeServices.NodeServicesImpl.<InvokeExportWithPossibleRetryAsync>d__10`1.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()
at Microsoft.AspNetCore.SpaServices.Prerendering.PrerenderTagHelper.<ProcessAsync>d__29.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.AspNetCore.Razor.Runtime.TagHelpers.TagHelperRunner.<RunAsync>d__0.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at AspNetCore._Views_Home_Index_cshtml.<ExecuteAsync>d__12.MoveNext() in /Docker/Views/Home/Index.cshtml:line 2
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.AspNetCore.Mvc.Razor.RazorView.<RenderPageCoreAsync>d__16.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.AspNetCore.Mvc.Razor.RazorView.<RenderPageAsync>d__15.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()
at Microsoft.AspNetCore.Mvc.Razor.RazorView.<RenderAsync>d__14.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.AspNetCore.Mvc.ViewFeatures.ViewExecutor.<ExecuteAsync>d__22.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.AspNetCore.Mvc.ViewFeatures.ViewExecutor.<ExecuteAsync>d__21.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.AspNetCore.Mvc.ViewResult.<ExecuteResultAsync>d__26.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.AspNetCore.Mvc.Internal.ResourceInvoker.<InvokeResultAsync>d__19.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.AspNetCore.Mvc.Internal.ResourceInvoker.<InvokeNextResultFilterAsync>d__24.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at Microsoft.AspNetCore.Mvc.Internal.ResourceInvoker.Rethrow(ResultExecutedContext context)
at Microsoft.AspNetCore.Mvc.Internal.ResourceInvoker.Next(State& next, Scope& scope, Object& state, Boolean& isCompleted)
at Microsoft.AspNetCore.Mvc.Internal.ResourceInvoker.<InvokeNextResourceFilter>d__22.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at Microsoft.AspNetCore.Mvc.Internal.ResourceInvoker.Rethrow(ResourceExecutedContext context)
at Microsoft.AspNetCore.Mvc.Internal.ResourceInvoker.Next(State& next, Scope& scope, Object& state, Boolean& isCompleted)
at Microsoft.AspNetCore.Mvc.Internal.ResourceInvoker.<InvokeFilterPipelineAsync>d__17.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.AspNetCore.Mvc.Internal.ResourceInvoker.<InvokeAsync>d__15.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.AspNetCore.Builder.RouterMiddleware.<Invoke>d__4.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.AspNetCore.Diagnostics.ExceptionHandlerMiddleware.<Invoke>d__6.MoveNext()
最佳答案
小滴上没有安装节点。这在您的堆栈跟踪中指出:
An unhandled exception has occurred: Failed to start Node process. To resolve this:.
[1] Ensure that Node.js is installed and can be found in one of the PATH directories.
Current PATH enviroment variable is: /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
Make sure the Node executable is in one of those directories, or update your PATH.
[2] See the InnerException for further details of the cause.
from
),因为它包含节点。
关于docker - Dockerfile和.net核心镜像,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/49419576/
我需要将 OCI 镜像 list 转换为 Docker v2.2 镜像格式,反之亦然。但我找不到两者之间的任何区别,是否有任何实际区别或它们相同? 最佳答案 Docker 镜像 list V 2,模式
LNMP 是代表 Linux 系统下的 Nginx、Mariadb、PHP 相结合而构建成的动态网站服务器架构。下面使用docker制作分布式lnmp 镜像。 1、docker 分布式 lnmp
你好,我创建了一个基础镜像;但是,每当我运行 docker build . 时,我都看不到成功构建 我的 docker 文件 FROM centos:7 ARG user=john ARG home=
我想要我的 iPhone 应用程序中有一个功能,可以将图像转换为类似镜像的方式。 就像如果有一个左手举起的人的图像,那么转换后的图像必须有右手举起的同一个人。 任何代码或链接将不胜感激 预先感谢您的帮
我们希望将一个Elasticsearch集群放置在kubernetes集群的顶部(当前有2个节点,但是我们计划增加它)。 是否可以通过使集群中的每个节点包含相同数据的方式配置elasticsearch
我试图了解 docker 如何在文件系统上存储图像和图层。构建图像时,图层出现在 /var/lib/docker/image/overlay2/layerdb 中,图像出现在 /var/lib/doc
所以我最近开始使用 docker,因为我认为让我的网站 dockerised 会很好。我有一个 super 简单的 docker-compose.yml 文件,其中仅包含 wordpress:late
我有一个 docker 镜像,叫它 dockerimage/test。每次我更新它时,我都会增加一个标签,所以 dockerimage/test:1、dockerimage/test:2 等等。 当我
我开始使用 Docker,我发现我可以将主图像存储库放在不同的磁盘上(符号链接(symbolic link)/var/lib/docker 到其他位置)。 但是,现在我想看看是否有办法将它拆分到多个磁
显然应用程序打包和部署似乎有两种做法 创建 Docker 镜像并部署它 从头开始构建和部署应用程序。 我对如何使用选项 1) 感到困惑。前提是你获取一个 docker 镜像并在任何平台上重复使用它。但
我有一个 UIView具有透明背景和一些按钮。我想捕获 View 的绘图,将其缩小,然后在屏幕上的其他位置重新绘制(镜像)它。 (在另一个 View 之上。)按钮可以更改,因此它不是静态的。 最好的方
我正在为一个项目编写测试,我想测试和验证一个 docker 镜像构建。但我不想推送图像。 我希望图像构建在 CI(如 taskcluster)上并运行测试。 最佳答案 您需要使用 taskcluste
我想复制每个 html 页面中的代码,同时添加一些更改: 例子: Any text (even if includes :., 输出: Any text (even if includes :.,
我使用三星 ARM Cortex A9 Exynos4412 板。我在板上启动“linux + Qt”img。但是板上没有包管理器,也没有 make 、 gcc 命令。在/bin 文件中有文件 Bus
是否有可能以某种方式设置一个 git 存储库,该存储库像通常的 --mirror 一样用于 pull 入它,但在将从推送到另一个存储库时没有强制? 最佳答案 您可以像这样添加 --no-force 来
背景 最近在巡检过程中,发现harbor存储空间使用率已经达到了80%。于是,去看了一下各项目下的镜像标签数。发现有个别项目下的镜像标签数竟然有好几百个。细问之下得知,该项目目前处于调试阶段
以下均在centos 7进行的操作 docker安装 ? 1
我知道如何删除 N 天前创建的旧 Docker 镜像。 See here 但我真正想做的是删除过去 N 天未使用的旧 Docker 镜像。 目标是保留经常使用的图像,即使在我进行清理时没有容器实际使用
我有一个自定义的 docker 镜像,已经构建好了。没有可用的 Dockerfile。在容器内部,可以使用自定义用户,而不是 root,比如 test。此用户已附加到组 test。这是容器的默认用户。
我有一个开发数据库,我想将其提交到 docker 镜像中,然后推送到私有(private)存储库并用于本地开发和 CI 构建。 数据库保存为SQL备份,我可以通过将备份文件映射到官方镜像的/doc
我是一名优秀的程序员,十分优秀!