AmpScm / SharpSvn

Subversion wrapped for .Net 4.0+ and .Net Core
Apache License 2.0
58 stars 19 forks source link

Getting 'System.IO.FileNotFoundException: Could not load file or assembly 'SharpSvn' The system cannot find the file specified' on docker container #88

Closed StuSten closed 7 months ago

StuSten commented 8 months ago

Hi Im building a docker container using ubi8/dotnet-70-runtime with SharpSvn and im getting the following stack trace:

fail: Microsoft.AspNetCore.Diagnostics.ExceptionHandlerMiddleware[1] An unhandled exception has occurred while executing the request. System.IO.FileNotFoundException: Could not load file or assembly 'SharpSvn, Version=1.14001.156.0, Culture=neutral, PublicKeyToken=d729672594885a28'. The system cannot find the file specified. File name: 'SharpSvn, Version=1.14001.156.0, Culture=neutral, PublicKeyToken=d729672594885a28' at rundeck_supporting_services.Controllers.SVNController.SVNLookupByPath(String server, String path, String protocol, String port, Boolean showFiles, Int32 limit) at lambda_method1(Closure, Object, Object[]) at Microsoft.AspNetCore.Mvc.Infrastructure.ActionMethodExecutor.SyncObjectResultExecutor.Execute(ActionContext actionContext, IActionResultTypeMapper mapper, ObjectMethodExecutor executor, Object controller, Object[] arguments) at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.InvokeActionMethodAsync() at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.Next(State& next, Scope& scope, Object& state, Boolean& isCompleted) at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.InvokeNextActionFilterAsync() --- End of stack trace from previous location ---

StuSten commented 8 months ago

Just some further detail, the image im using is ubi8/dotnet-70-runtime and im using the 64 bit dll but I tried 32 bit and had the same issue.

rhuijben commented 8 months ago

SharpSvn should work in a windows container. You need the right IJW dll if you use the .net core version of the SharpSvn build and perhaps the right MSVCRT if that isn't included in the base image.

SharpSvn isn't compatible with Linux +- by design, as the C++ layer used for compiling SharpSvn doesn't support generating linux compatible code.

StuSten commented 7 months ago

Thanks. It was the linux container being unsupported is the issue.