Skip to content
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

config folder missing in windows build #13

Open
akrotor opened this issue Dec 20, 2024 · 2 comments
Open

config folder missing in windows build #13

akrotor opened this issue Dec 20, 2024 · 2 comments

Comments

@akrotor
Copy link

akrotor commented Dec 20, 2024

Upon running compressarr.exe i receive the below complaining about path not found - There appears to simply be no config dir in the windows release, and it isn't created upon first-run / exit.

I tried browsing to the localhost page and while it loads, perhaps unsurprisingly all the buttons except help are unresponsive.

19:11:30 info: Compressarr.Initialisation.StartupBackgroundService[0]
StartupBackgroundService is running.
19:11:30 info: Compressarr.Initialisation.StartupBackgroundService[0]
StartupBackgroundService is working.
19:11:30 fail: Compressarr.Application.ApplicationInitialiser[0]
=> Initialising Application
Initialisation Error
System.IO.DirectoryNotFoundException: Could not find a part of the path 'C:\compressarr\config\mediaInfo.db'.
at Microsoft.Win32.SafeHandles.SafeFileHandle.CreateFile(String fullPath, FileMode mode, FileAccess access, FileShare share, FileOptions options)
at Microsoft.Win32.SafeHandles.SafeFileHandle.Open(String fullPath, FileMode mode, FileAccess access, FileShare share, FileOptions options, Int64 preallocationSize)
at System.IO.Strategies.OSFileStreamStrategy..ctor(String path, FileMode mode, FileAccess access, FileShare share, FileOptions options, Int64 preallocationSize)
at System.IO.Strategies.FileStreamHelpers.ChooseStrategyCore(String path, FileMode mode, FileAccess access, FileShare share, FileOptions options, Int64 preallocationSize)
at System.IO.Strategies.FileStreamHelpers.ChooseStrategy(FileStream fileStream, String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, FileOptions options, Int64 preallocationSize)
at System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, FileOptions options)
at LiteDB.Engine.FileStreamFactory.GetStream(Boolean canWrite, Boolean sequencial)
at LiteDB.Engine.StreamPool.<>c__DisplayClass3_0.<.ctor>b__0()
at System.Lazy1.ViaFactory(LazyThreadSafetyMode mode) at System.Lazy1.ExecutionAndPublication(LazyHelper executionAndPublication, Boolean useDefaultConstructor)
at System.Lazy1.CreateValue() at System.Lazy1.get_Value()
at LiteDB.Engine.StreamPool.get_Writer()
at LiteDB.Engine.DiskService..ctor(EngineSettings settings, Int32[] memorySegmentSizes)
at LiteDB.Engine.LiteEngine..ctor(EngineSettings settings)
at LiteDB.ConnectionString.CreateEngine()
at LiteDB.LiteDatabase..ctor(ConnectionString connectionString, BsonMapper mapper)
at Compressarr.Application.ApplicationInitialiser.ApplyDatabaseTransforms() in D:\a\Compressarr\Compressarr\Compressarr\Application\ApplicationInitialiser.cs:line 112
at Compressarr.Application.ApplicationInitialiser.InitialiseAsync() in D:\a\Compressarr\Compressarr\Compressarr\Application\ApplicationInitialiser.cs:line 54
19:11:30 info: Microsoft.Hosting.Lifetime[14]
Now listening on: http://localhost:5000
19:11:30 info: Microsoft.Hosting.Lifetime[14]
Now listening on: https://localhost:5001
19:11:30 info: Microsoft.Hosting.Lifetime[0]
Application started. Press Ctrl+C to shut down.
19:11:30 info: Microsoft.Hosting.Lifetime[0]
Hosting environment: Production
19:11:30 info: Microsoft.Hosting.Lifetime[0]
Content root path: C:\compressarr\

@OFark
Copy link
Owner

OFark commented Jan 2, 2025

Wow, someone running it on Windows. I'm not sure I ever tested that, it probably needs the Config directory created where ever you've extracted it. It's supposed to be run in a Docker environment with a Path for the config. It's .net so there's no reason why it shouldn't run in Windows, I certainly developed and tested in a Windows environment, I must have had the folder already from testing.

@spacezorro
Copy link

Adding

RUN mkdir /config/

to the Dockerfile fixes this

The config will not persist past container restart though.

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

No branches or pull requests

3 participants