-
Notifications
You must be signed in to change notification settings - Fork 663
Closed
Description
I would like to use GitVersion inside the OpenShift Jenkins 2 Docker image which is based on CentOS 7. Unfortunately, I'm getting the following error:
System.TypeInitializationException: The type initializer for 'LibGit2Sharp.Core.NativeMethods' threw an exception. ---> System.DllNotFoundException: lib/linux/x86_64/libgit2-baa87df.so
at (wrapper managed-to-native) LibGit2Sharp.Core.NativeMethods:git_libgit2_init ()
at LibGit2Sharp.Core.NativeMethods+LibraryLifetimeObject..ctor () [0x00006] in <1a5aafd5a5444cd6a1420741ccbb6f8a>:0
at LibGit2Sharp.Core.NativeMethods..cctor () [0x00058] in <1a5aafd5a5444cd6a1420741ccbb6f8a>:0
--- End of inner exception stack trace ---
at LibGit2Sharp.Core.NativeMethods+LibraryLifetimeObject.Finalize () [0x00000] in <1a5aafd5a5444cd6a1420741ccbb6f8a>:0
I do have libcurl installed but I guess the problem is that CentOS uses libcurl 4 and not 3.
I have created a standalone Docker image to reproduce the problem which you can execute as follows:
docker run omallo/git-version-centos7
The contents of the Dockerfile are the following:
FROM centos:centos7
RUN yum install -y yum-utils && \
rpm --import "http://keyserver.ubuntu.com/pks/lookup?op=get&search=0x3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF" && \
yum-config-manager --add-repo http://download.mono-project.com/repo/centos/ && \
yum -y install libcurl && \
yum -y install mono-complete && \
yum clean all && \
curl -L -o /tmp/GitVersion_3.6.5.zip https://github.com/GitTools/GitVersion/releases/download/v3.6.5/GitVersion_3.6.5.zip && \
unzip /tmp/GitVersion_3.6.5.zip -d /usr/local/GitVersion_3.6.5 && \
rm -f /tmp/GitVersion_3.6.5.zip
ENTRYPOINT ["mono", "/usr/local/GitVersion_3.6.5/GitVersion.exe"]
Can you say whether the problem indeed is that CentOS uses version 4 of libcurl and, if so, is there any possibility to get GitVersion running with that version?
Metadata
Metadata
Assignees
Labels
No labels