且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

为 ASP.NET Core 2.1 Angular 项目配置 Dockerfile

更新时间:2023-02-16 12:51:50

在 microsoft/dotnet:2.1-aspnetcore-runtime 容器镜像中未安装 npm/nodejs.要在容器中安装它,请更新 docker 文件

In the microsoft/dotnet:2.1-aspnetcore-runtime container image npm/nodejs is not installed. To install this in the container update the docker file

FROM microsoft/dotnet:2.1-aspnetcore-runtime AS base

# Setup NodeJs
RUN apt-get update && 
    apt-get install -y wget && 
    apt-get install -y gnupg2 && 
    wget -qO- https://deb.nodesource.com/setup_6.x | bash - && 
    apt-get install -y build-essential nodejs
# End setup

WORKDIR /app
EXPOSE 80

只有 Angular CLI 实时重新加载不起作用.

Only Angular CLI live reload is not working.