minio / mint

Collection of tests to detect overall correctness of MinIO server.
Apache License 2.0
78 stars 50 forks source link

docker build broken on dotnet install step #337

Closed halkyon closed 2 years ago

halkyon commented 2 years ago

When building the mint image, the dotnet step appears to be broken:

...
Running /mint/build/minio-dotnet/install.sh
...
/usr/share/dotnet/sdk/2.1.818/Sdks/Microsoft.NET.Sdk/targets/Microsoft.NET.Sdk.CrossTargeting.targets(31,5): error : The 'Publish' target is not supported without specifying a target framework. The current project targets multiple frameworks, please specify the framework for the published application. [/mint/run/core/minio-dotnet/Minio.Functional.Tests.csproj]
The command '/bin/sh -c cd /mint && /mint/release.sh' returned a non-zero code: 1

Perhaps it broke with this SDK change: https://github.com/minio/minio-dotnet/commit/45cc7daff836922e20755e00683ec1b4951cee8d

halkyon commented 2 years ago

I believe this could be fixed by specifying --framework net6.0 to the dotnet publish command in build/minio-dotnet/install.sh. At least, this is what worked for me locally, but I'm no expert in how the dotnet tests should be run.

Mint tests also install the dotnet-sdk-2.1 package, which is now out of date. Perhaps this could install a recent version like dotnet-sdk-6.0 instead.

ebozduman commented 2 years ago

@halkyon Yes. You can fix it be specifying the framework and correct, we don't need to install dotnet sdk 2.1. Thanks for your input.

halkyon commented 2 years ago

I proposed a fix in https://github.com/minio/mint/pull/338 which fixes the mint image build, however, the mint dotnet tests fail when using the new image (test output in the PR). I ran it against an older mint image and the test passed.

ebozduman commented 2 years ago

@halkyon We appreciate very much your help and effort. For a PR to qualify, we need all tests to pass.

halkyon commented 2 years ago

@ebozduman I guess what I was trying to say in my previous comment (but did not elaborate) was that some help solving this would be great, because I don't know why it's failing. It could be a change in the upstream minio-dotnet tests that now makes the minio tests fail, or relating to the way dotnet is set up in the mint build, but I'm not really sure what's going on.

ebozduman commented 2 years ago

@halkyon No problem at all. I guess I was also vague. I meant we/I'll do the rest.