diff options
Diffstat (limited to 'MediaBrowser.Server.Mono/MonoAppHost.cs')
| -rw-r--r-- | MediaBrowser.Server.Mono/MonoAppHost.cs | 97 |
1 files changed, 10 insertions, 87 deletions
diff --git a/MediaBrowser.Server.Mono/MonoAppHost.cs b/MediaBrowser.Server.Mono/MonoAppHost.cs index 932e2d6cd..e9ded5cd5 100644 --- a/MediaBrowser.Server.Mono/MonoAppHost.cs +++ b/MediaBrowser.Server.Mono/MonoAppHost.cs @@ -1,9 +1,12 @@ using System; using System.Collections.Generic; using System.Reflection; +using Emby.Server.Connect; using Emby.Server.Core; using Emby.Server.Implementations; -using Emby.Server.Implementations.FFMpeg; +using Emby.Server.Sync; +using MediaBrowser.Controller.Connect; +using MediaBrowser.Controller.Sync; using MediaBrowser.IsoMounter; using MediaBrowser.Model.IO; using MediaBrowser.Model.Logging; @@ -26,61 +29,14 @@ namespace MediaBrowser.Server.Mono } } - public override bool CanSelfUpdate + protected override IConnectManager CreateConnectManager() { - get - { - return false; - } - } - - protected override FFMpegInstallInfo GetFfmpegInstallInfo() - { - var info = new FFMpegInstallInfo(); - - // Windows builds: http://ffmpeg.zeranoe.com/builds/ - // Linux builds: http://johnvansickle.com/ffmpeg/ - // OS X builds: http://ffmpegmac.net/ - // OS X x64: http://www.evermeet.cx/ffmpeg/ - - var environment = (MonoEnvironmentInfo) EnvironmentInfo; - - if (environment.IsBsd) - { - - } - else if (environment.OperatingSystem == Model.System.OperatingSystem.Linux) - { - info.FFMpegFilename = "ffmpeg"; - info.FFProbeFilename = "ffprobe"; - info.ArchiveType = "7z"; - info.Version = "20160215"; - info.DownloadUrls = GetDownloadUrls(); - } - - // No version available - user requirement - info.DownloadUrls = new string[] { }; - - return info; + return new ConnectManager(); } - private string[] GetDownloadUrls() + protected override ISyncManager CreateSyncManager() { - switch (EnvironmentInfo.SystemArchitecture) - { - case Architecture.X64: - return new[] - { - "https://github.com/MediaBrowser/Emby.Resources/raw/master/ffmpeg/linux/ffmpeg-git-20160215-64bit-static.7z" - }; - case Architecture.X86: - return new[] - { - "https://github.com/MediaBrowser/Emby.Resources/raw/master/ffmpeg/linux/ffmpeg-git-20160215-32bit-static.7z" - }; - } - - return new string[] { }; + return new SyncManager(); } protected override void RestartInternal() @@ -103,6 +59,8 @@ namespace MediaBrowser.Server.Mono var list = new List<Assembly>(); list.Add(typeof(LinuxIsoManager).Assembly); + list.Add(typeof(ConnectManager).Assembly); + list.Add(typeof(SyncManager).Assembly); return list; } @@ -137,40 +95,5 @@ namespace MediaBrowser.Server.Mono return new Version(1, 0); } - - protected override void AuthorizeServer() - { - throw new NotImplementedException(); - } - - protected override void ConfigureAutoRunInternal(bool autorun) - { - throw new NotImplementedException(); - } - - protected override void EnableLoopbackInternal(string appName) - { - } - - public override bool SupportsRunningAsService - { - get - { - return false; - } - } - - public override bool SupportsAutoRunAtStartup - { - get { return false; } - } - - public override bool IsRunningAsService - { - get - { - return false; - } - } } } |
