Skip to content

Conversation

rhysparry
Copy link
Contributor

@rhysparry rhysparry commented Aug 9, 2024

Background

With the EOL of .NET 6 coming in November, this PR sets up Tentacle to build versions targeting .NET 8.

Results

  • Adds a .NET8 version of the Tentacle (and other tooling)

resolves #999

How to review this PR

Quality ✔️

Pre-requisites

  • I have read How we use GitHub Issues for help deciding when and where it's appropriate to make an issue.
  • I have considered informing or consulting the right people, according to the ownership map.
  • I have considered appropriate testing for my change.

@rhysparry rhysparry force-pushed the sast/sc-85314/dotnet-8-targeting branch from bf34e45 to 869b05f Compare August 13, 2024 02:07
@rhysparry rhysparry force-pushed the sast/sc-85314/dotnet-8-targeting branch from 869b05f to 37df7a7 Compare August 13, 2024 04:12
// Tentacle 8.2 is/was built on .NET8, previous versions were built on .NET6
string runtimeForVersion = version.Major >= 8 && version.Minor >= 2
? RuntimeDetection.DotNet8
: RuntimeDetection.DotNet6;
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

With everything on .NET 8 we might not need this any more.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

At this point, I'll revert the change first to get a green build.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is likely to be the reason, https://docs.google.com/document/d/1bVnkDoctYpf-GdkoAPzGTc5Oyj_O2NlwqRl43Gv3MwM/edit#bookmark=id.976uxf7b549q

  • I didn't do any further investigation though.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Revert this

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Or don't and reference the Octopus Server PR where the same change was made

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reverted. (Will observe any build issue)

<PackageReference Include="KubernetesClient" Version="13.0.26" />
</ItemGroup>
<ItemGroup Condition="'$(TargetFramework)' == 'net8.0' Or '$(TargetFramework)' == 'net8.0-windows'">
<PackageReference Include="KubernetesClient" Version="13.0.26" />
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Check if this has been updated in main

static byte[] GetEncryptionKey(string encryptionPassword)
{
#if NET8_0_OR_GREATER
using var passwordGenerator = new Rfc2898DeriveBytes(encryptionPassword, PasswordPaddingSalt, PasswordSaltIterations, HashAlgorithmName.SHA1);
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

NET8 requires the encryption algorithm is explicit as the other overload has been marked as obsolete.

Internally, it used the SHA1 algorithm.

#endif
}

#if NET6_0_OR_GREATER
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Check if this should be NET8_0_OR_GREATER instead

@michaelongso michaelongso marked this pull request as ready for review September 3, 2024 05:16
@michaelongso michaelongso requested review from a team as code owners September 3, 2024 05:16
@michaelongso
Copy link
Contributor

We reviewed this work as a mob.
cc: @rhysparry, @acodrington

Copy link
Contributor

@MissedTheMark MissedTheMark left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

MD code owner review: approved! ✅
Note that this isn't a review of the functionality, the PR still requires a full review from the originating team.

@gb-8 gb-8 merged commit ab76266 into main Sep 3, 2024
53 checks passed
@gb-8 gb-8 deleted the sast/sc-85314/dotnet-8-targeting branch September 3, 2024 06:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Update Tentacle to .NET 8
5 participants