tytd/Dockerfile

17 lines
475 B
Docker
Raw Permalink Normal View History

2022-05-14 01:49:10 +00:00
FROM mcr.microsoft.com/dotnet/sdk:6.0 AS build-env
WORKDIR /app
RUN git clone https://github.com/tesses50/tytd-2022 .
WORKDIR /app/Tesses.YouTubeDownloader.Net6
# Restore as distinct layers
RUN dotnet restore
# Build and publish a release
RUN dotnet publish -c Release -o /app/out
# Build runtime image
FROM mcr.microsoft.com/dotnet/runtime:6.0
WORKDIR /app
2022-06-12 01:13:09 +00:00
EXPOSE 3252
2022-05-14 01:49:10 +00:00
COPY --from=build-env /app/out .
2022-06-12 01:13:09 +00:00
ENTRYPOINT ["dotnet", "Tesses.YouTubeDownloader.Net6.dll","--docker"]