diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 24b71e1fe..e9e7a6419 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -19,7 +19,7 @@ jobs: - name: Setup .NET Core uses: actions/setup-dotnet@v1 with: - dotnet-version: 5.0.x + dotnet-version: 6.0.x - name: Clean run: dotnet clean --configuration Release && dotnet nuget locals all --clear diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index e09b23624..78606c6eb 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -28,7 +28,7 @@ jobs: - name: Setup .NET Core uses: actions/setup-dotnet@v1 with: - dotnet-version: 5.0.x + dotnet-version: 6.0.x - name: Clean run: dotnet clean --configuration Release && dotnet nuget locals all --clear @@ -44,7 +44,7 @@ jobs: release_name="ErsatzTV-$tag-${{ matrix.target }}" # Build everything - dotnet publish ErsatzTV/ErsatzTV.csproj --framework net5.0 --runtime "${{ matrix.target }}" -c Release -o "$release_name" /property:InformationalVersion="${tag:1}-${{ matrix.target }}" /property:PublishSingleFile=true --self-contained true + dotnet publish ErsatzTV/ErsatzTV.csproj --framework net6.0 --runtime "${{ matrix.target }}" -c Release -o "$release_name" /property:InformationalVersion="${tag:1}-${{ matrix.target }}" /property:EnableCompressionInSingleFile=true /property:PublishSingleFile=true --self-contained true # Pack files if [ "${{ matrix.target }}" == "win-x64" ]; then diff --git a/ErsatzTV.Application/ErsatzTV.Application.csproj b/ErsatzTV.Application/ErsatzTV.Application.csproj index da45d32e6..c05978d31 100644 --- a/ErsatzTV.Application/ErsatzTV.Application.csproj +++ b/ErsatzTV.Application/ErsatzTV.Application.csproj @@ -1,7 +1,7 @@ - net5.0 + net6.0 VSTHRD200 embedded diff --git a/ErsatzTV.Core.Tests/ErsatzTV.Core.Tests.csproj b/ErsatzTV.Core.Tests/ErsatzTV.Core.Tests.csproj index d406e991e..5de853473 100644 --- a/ErsatzTV.Core.Tests/ErsatzTV.Core.Tests.csproj +++ b/ErsatzTV.Core.Tests/ErsatzTV.Core.Tests.csproj @@ -1,7 +1,7 @@ - net5.0 + net6.0 VSTHRD200 diff --git a/ErsatzTV.Core.Tests/FFmpeg/TranscodingTests.cs b/ErsatzTV.Core.Tests/FFmpeg/TranscodingTests.cs index 9a8b4dfc3..b1dc1b180 100644 --- a/ErsatzTV.Core.Tests/FFmpeg/TranscodingTests.cs +++ b/ErsatzTV.Core.Tests/FFmpeg/TranscodingTests.cs @@ -3,6 +3,7 @@ using System.Collections.Generic; using System.Diagnostics; using System.IO; using System.Linq; +using System.Security.Cryptography; using System.Threading.Tasks; using ErsatzTV.Core.Domain; using ErsatzTV.Core.Domain.Filler; @@ -237,7 +238,7 @@ namespace ErsatzTV.Core.Tests.FFmpeg return string.Empty; } - using var sha = new System.Security.Cryptography.SHA256Managed(); + using var sha = SHA256.Create(); byte[] textData = System.Text.Encoding.UTF8.GetBytes(text); byte[] hash = sha.ComputeHash(textData); return BitConverter.ToString(hash).Replace("-", string.Empty); diff --git a/ErsatzTV.Core/ErsatzTV.Core.csproj b/ErsatzTV.Core/ErsatzTV.Core.csproj index 9ef816951..94d629edc 100644 --- a/ErsatzTV.Core/ErsatzTV.Core.csproj +++ b/ErsatzTV.Core/ErsatzTV.Core.csproj @@ -1,7 +1,7 @@ - net5.0 + net6.0 VSTHRD200 embedded diff --git a/ErsatzTV.Core/Metadata/FolderEtag.cs b/ErsatzTV.Core/Metadata/FolderEtag.cs index 3a1a9d8d3..5e4d7b0f4 100644 --- a/ErsatzTV.Core/Metadata/FolderEtag.cs +++ b/ErsatzTV.Core/Metadata/FolderEtag.cs @@ -9,7 +9,7 @@ namespace ErsatzTV.Core.Metadata { public static class FolderEtag { - private static readonly MD5CryptoServiceProvider Crypto = new(); + private static readonly MD5 Crypto = MD5.Create(); public static string Calculate(string folder, ILocalFileSystem localFileSystem) { diff --git a/ErsatzTV.Infrastructure/ErsatzTV.Infrastructure.csproj b/ErsatzTV.Infrastructure/ErsatzTV.Infrastructure.csproj index 33668eeca..1fb873099 100644 --- a/ErsatzTV.Infrastructure/ErsatzTV.Infrastructure.csproj +++ b/ErsatzTV.Infrastructure/ErsatzTV.Infrastructure.csproj @@ -1,7 +1,7 @@ - net5.0 + net6.0 true VSTHRD200 embedded diff --git a/ErsatzTV.Infrastructure/Images/ImageCache.cs b/ErsatzTV.Infrastructure/Images/ImageCache.cs index 79fa51082..5ea570755 100644 --- a/ErsatzTV.Infrastructure/Images/ImageCache.cs +++ b/ErsatzTV.Infrastructure/Images/ImageCache.cs @@ -18,12 +18,12 @@ namespace ErsatzTV.Infrastructure.Images { public class ImageCache : IImageCache { - private static readonly SHA1CryptoServiceProvider Crypto; + private static readonly SHA1 Crypto; private readonly ILocalFileSystem _localFileSystem; private readonly ILogger _logger; private readonly IMemoryCache _memoryCache; - static ImageCache() => Crypto = new SHA1CryptoServiceProvider(); + static ImageCache() => Crypto = SHA1.Create(); public ImageCache(ILocalFileSystem localFileSystem, IMemoryCache memoryCache, ILogger logger) { diff --git a/ErsatzTV/ErsatzTV.csproj b/ErsatzTV/ErsatzTV.csproj index f6b5f3ab3..db4f2c2d0 100644 --- a/ErsatzTV/ErsatzTV.csproj +++ b/ErsatzTV/ErsatzTV.csproj @@ -1,7 +1,7 @@ - net5.0 + net6.0 VSTHRD200 true embedded @@ -21,7 +21,7 @@ - + all runtime; build; native; contentfiles; analyzers; buildtransitive diff --git a/docker/Dockerfile b/docker/Dockerfile index fe613dc69..348a792e5 100644 --- a/docker/Dockerfile +++ b/docker/Dockerfile @@ -1,11 +1,11 @@ -FROM mcr.microsoft.com/dotnet/aspnet:5.0-focal-amd64 AS dotnet-runtime +FROM mcr.microsoft.com/dotnet/aspnet:6.0-focal-amd64 AS dotnet-runtime FROM jasongdove/ffmpeg:4.4-ubuntu2004 AS runtime-base COPY --from=dotnet-runtime /usr/share/dotnet /usr/share/dotnet RUN apt-get update && DEBIAN_FRONTEND="noninteractive" apt-get install -y libicu-dev tzdata # https://hub.docker.com/_/microsoft-dotnet -FROM mcr.microsoft.com/dotnet/sdk:5.0 AS build +FROM mcr.microsoft.com/dotnet/sdk:6.0 AS build RUN apt-get update && apt-get install -y ca-certificates WORKDIR /source diff --git a/docker/nvidia/Dockerfile b/docker/nvidia/Dockerfile index 234919957..a0b87b26e 100644 --- a/docker/nvidia/Dockerfile +++ b/docker/nvidia/Dockerfile @@ -1,5 +1,5 @@ # https://hub.docker.com/_/microsoft-dotnet -FROM mcr.microsoft.com/dotnet/sdk:5.0 AS build +FROM mcr.microsoft.com/dotnet/sdk:6.0 AS build RUN apt-get update && apt-get install -y ca-certificates WORKDIR /source diff --git a/docker/nvidia/ffmpeg.Dockerfile b/docker/nvidia/ffmpeg.Dockerfile index b7396b043..e15ba848a 100644 --- a/docker/nvidia/ffmpeg.Dockerfile +++ b/docker/nvidia/ffmpeg.Dockerfile @@ -1,4 +1,4 @@ -FROM mcr.microsoft.com/dotnet/aspnet:5.0-focal-amd64 AS dotnet-runtime +FROM mcr.microsoft.com/dotnet/aspnet:6.0-focal-amd64 AS dotnet-runtime FROM jasongdove/ffmpeg-base:4.4-nvidia2004 AS runtime-base COPY --from=dotnet-runtime /usr/share/dotnet /usr/share/dotnet diff --git a/docker/vaapi/Dockerfile b/docker/vaapi/Dockerfile index 09d640063..7ede6fe24 100644 --- a/docker/vaapi/Dockerfile +++ b/docker/vaapi/Dockerfile @@ -1,5 +1,5 @@ # https://hub.docker.com/_/microsoft-dotnet -FROM mcr.microsoft.com/dotnet/sdk:5.0 AS build +FROM mcr.microsoft.com/dotnet/sdk:6.0 AS build RUN apt-get update && apt-get install -y ca-certificates WORKDIR /source diff --git a/docker/vaapi/ffmpeg.Dockerfile b/docker/vaapi/ffmpeg.Dockerfile index 47bb0ae4f..7d14939ae 100644 --- a/docker/vaapi/ffmpeg.Dockerfile +++ b/docker/vaapi/ffmpeg.Dockerfile @@ -1,4 +1,4 @@ -FROM mcr.microsoft.com/dotnet/aspnet:5.0-focal-amd64 AS dotnet-runtime +FROM mcr.microsoft.com/dotnet/aspnet:6.0-focal-amd64 AS dotnet-runtime FROM jasongdove/ffmpeg-base:4.4-vaapi2004 AS runtime-base COPY --from=dotnet-runtime /usr/share/dotnet /usr/share/dotnet diff --git a/global.json b/global.json new file mode 100644 index 000000000..f443bd421 --- /dev/null +++ b/global.json @@ -0,0 +1,7 @@ +{ + "sdk": { + "version": "6.0", + "rollForward": "latestMajor", + "allowPrerelease": true + } +} \ No newline at end of file