chore: init commit from GitHub
This commit is contained in:
15
TelegramBot/Dockerfile
Normal file
15
TelegramBot/Dockerfile
Normal file
@@ -0,0 +1,15 @@
|
||||
# https://hub.docker.com/_/microsoft-dotnet
|
||||
FROM mcr.microsoft.com/dotnet/sdk:8.0 AS build
|
||||
WORKDIR /source
|
||||
|
||||
# copy csproj and restore as distinct layers
|
||||
COPY ./ ./
|
||||
RUN dotnet restore
|
||||
WORKDIR /source/TelegramBot
|
||||
RUN dotnet publish -c release -o /app --no-restore
|
||||
|
||||
# final stage/image
|
||||
FROM mcr.microsoft.com/dotnet/aspnet:8.0
|
||||
WORKDIR /app
|
||||
COPY --from=build /app ./
|
||||
ENTRYPOINT ["dotnet", "/app/TelegramBot.dll"]
|
||||
Reference in New Issue
Block a user