reactredux/webapi/ClientApp/Dockerfile

22 lines
583 B
Docker

#Depending on the operating system of the host machines(s) that will build or run the containers, the image specified in the FROM statement may need to be changed.
#For more information, please see https://aka.ms/containercompat
FROM node:16 AS base
WORKDIR /app
EXPOSE 80
EXPOSE 443
FROM node:16 AS build
WORKDIR /src
COPY ["ClientApp/package.json", "ClientApp/"]
WORKDIR "/src/ClientApp"
COPY . .
RUN npm install
RUN npm install --location=global react-scripts
#FROM base AS final
#WORKDIR "/src/ClientApp"
#COPY --from=build /app/publish .
ENTRYPOINT ["npm", "run", "start"]