-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
59 lines (44 loc) · 1.54 KB
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
FROM mcr.microsoft.com/dotnet/core/aspnet:2.2-stretch-slim AS base
#install application for get HW info
RUN apt-get update
# install System.Drawing native dependencies
RUN apt-get update
RUN apt-get install -y --allow-unauthenticated
RUN apt-get install -y libc6-dev
RUN apt-get install -y libgdiplus
RUN apt-get install -y libx11-dev
RUN apt-get install -y mc
RUN apt-get install -y curl
RUN apt-get install -y hwinfo
RUN apt-get install -y busybox
RUN apt-get install -y iputils-ping
RUN apt-get install -y nodejs
#RUN apt-get build-dep libgdiplus
#RUN apt-get install -y libgdiplus
#RUN apt-get install -y --allow-unauthenticated libc6-dev
#RUN apt-get install -y --allow-unauthenticated libc6-dev libgdiplus libx11-dev
#National Language (locale) data
ENV DOTNET_SYSTEM_GLOBALIZATION_INVARIANT false
RUN apt-get install -y locales
RUN locale-gen uk_UA.UTF-8
ENV LC_ALL uk_UA.UTF-8
ENV LANG uk_UA.UTF-8
WORKDIR /app
EXPOSE 80
RUN curl -sL https://deb.nodesource.com/setup_12.x | bash -
RUN apt-get install -y nodejs
FROM mcr.microsoft.com/dotnet/core/sdk:2.2-stretch AS build
RUN curl -sL https://deb.nodesource.com/setup_12.x | bash -
RUN apt-get install -y nodejs
WORKDIR /src
COPY ["CarParts/CarParts.csproj", "CarParts/"]
RUN dotnet restore "CarParts/CarParts.csproj"
COPY . .
WORKDIR "/src/CarParts"
RUN dotnet build "CarParts.csproj" -c Release -o /app/build
FROM build AS publish
RUN dotnet publish "CarParts.csproj" -c Release -o /app/publish
FROM base AS final
WORKDIR /app
COPY --from=publish /app/publish .
ENTRYPOINT ["dotnet", "CarParts.dll"]