override port
This commit is contained in:
parent
8c517cb574
commit
563013e124
@ -1,21 +0,0 @@
|
||||
#See https://aka.ms/containerfastmode to understand how Visual Studio uses this Dockerfile to build your images for faster debugging.
|
||||
|
||||
FROM mcr.microsoft.com/dotnet/core/aspnet:3.1-buster-slim AS base
|
||||
WORKDIR /app
|
||||
EXPOSE 80
|
||||
|
||||
FROM mcr.microsoft.com/dotnet/core/sdk:3.1-buster AS build
|
||||
WORKDIR /src
|
||||
COPY ["ELT/ELT.csproj", "ELT/"]
|
||||
RUN dotnet restore "ELT/ELT.csproj"
|
||||
COPY . .
|
||||
WORKDIR "/src/ELT"
|
||||
RUN dotnet build "ELT.csproj" -c Release -o /app/build
|
||||
|
||||
FROM build AS publish
|
||||
RUN dotnet publish "ELT.csproj" -c Release -o /app/publish
|
||||
|
||||
FROM base AS final
|
||||
WORKDIR /app
|
||||
COPY --from=publish /app/publish .
|
||||
ENTRYPOINT ["dotnet", "ELT.dll"]
|
||||
@ -13,7 +13,11 @@ namespace ELT
|
||||
public static IHostBuilder CreateHostBuilder(string[] args)
|
||||
{
|
||||
return Host.CreateDefaultBuilder(args)
|
||||
.ConfigureWebHostDefaults(webBuilder => { webBuilder.UseStartup<Startup>(); });
|
||||
.ConfigureWebHostDefaults(webBuilder =>
|
||||
{
|
||||
webBuilder.UseStartup<Startup>();
|
||||
webBuilder.UseKestrel(options => { options.ListenAnyIP(2121); });
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -26,7 +26,7 @@
|
||||
"eltPassword": "evo12345",
|
||||
"eltLogin": "dmitrienko"
|
||||
},
|
||||
"applicationUrl": "http://localhost:5000"
|
||||
"applicationUrl": "http://localhost:2121"
|
||||
},
|
||||
"Docker": {
|
||||
"commandName": "Docker",
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user