-
Notifications
You must be signed in to change notification settings - Fork 654
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
GitVersionTask on the dotnet SDK docker image (microsoft/dotnet:2.1-sdk; Debian 9) #1473
Comments
How are you using GitVersionTask inside this docker image? Can u share pls ? |
Just install the NuGet package GitVersionTask (I have version 4.0.0-beta0014 installed) and build your project. Check the output dll file and you'll see the assembly version has been updated. |
For running on net.core 2.1.0 perhaps it's because you need #1422 ? |
@gerwim can you validate this agains the latest v.4.0.0 version and close the issue ? Thanks |
@arturcic I've installed GitVersionTask 4.0.0 and tried the build the project inside the microsoft/dotnet:2.1-sdk docker image, but still same error. I also tried to install
|
As above, I think you need the .net core 2.1 support which is in #1422 and not yet merged.. Otherwise try with a net core sdk 2.0 docker image. |
@dazinator Yeah, that's what I thought however Artur explicitly asked me to redo the test with the 2.1 version. Either way, let's wait until the PR is merged. ;-) |
I did that because the docker images that we currently have for version 4.0.0 are using microsoft/dotnet:2.1-runtime and they do work. |
@arturcic my guess is that the docker images we have currently for 2.1.0 are just calling |
you're absolutely right |
We should probably rename that PR to make it super clear that its a gitversiontask thing. GitVersion itself already runs on 2.1.0 as you have said! But i think there may have been some other changes in it like the global tool stuff so I guess its now more of a conglomorate of things :-) |
I have the same problem, here is a sample Dockerfile: FROM microsoft/dotnet:sdk
WORKDIR /app
RUN dotnet new console
RUN dotnet add package GitVersionTask
RUN dotnet build At this time I tested it |
@j2ghz I assume if you try that on a |
I guess so. I used the fix from the first post, which helped. In the end I turned gitversion off in docker builds, since I get |
If it helps - it appears as if the current version of the This (rather ugly) workaround seems to work, by installing OpenSSL 1.0.0 from Debian Jessie: Dockerfile:
jsessie.list:
|
With the latest version there is no need for the workaround. You can have a look at the way we ship the docker image with gitversion included https://github.com/GitTools/GitVersion/blob/master/src/Docker/netcoreapp2.1/linux/debian-9/Dockerfile There is no need to install |
As LibGit2Sharp was upgraded to version 0.26 in #1713, I think this problem is fixed. Please reopen this issue if the problem persists. |
So, I'm using GitVersionTask in my Docker build (using the officical microsoft/dotnet:2.1-sdk image). The issue I was having is the following error:
How I fixed it, is by install the library system wide and symlinking the location it's searching (used the LD_DEBUG env var to check what it was doing). In my Dockerfile I now have:
I created the issue just to let you know. The current version (15e1193) is hardcoded above, so it might change depending on the LibGit2Sharp.Core.NativeMethods library version is used.
The text was updated successfully, but these errors were encountered: