mirror of
https://github.com/Jackett/Jackett
synced 2025-01-01 12:46:23 +00:00
Make jackett and JackettUpdater executable
This commit is contained in:
parent
cc01b0ca05
commit
cf7ca97f9c
5 changed files with 24 additions and 10 deletions
|
@ -168,7 +168,7 @@ Task("Package-DotNetCore-macOS")
|
|||
Gzip($"./BuildOutput/{netCoreFramework}/{runtimeId}", $"./{artifactsDirName}", "Jackett", "Experimental.Jackett.Binaries.macOS.tar.gz");
|
||||
});
|
||||
|
||||
Task("Package-DotNetCore-LinuxAMD64")
|
||||
Task("Package-DotNetCore-LinuxAMDx64")
|
||||
.IsDependentOn("Clean")
|
||||
.Does(() =>
|
||||
{
|
||||
|
@ -185,7 +185,7 @@ Task("Package-DotNetCore-LinuxAMD64")
|
|||
CopyFileToDirectory("./install_service_systemd.sh", buildOutputPath);
|
||||
CopyFileToDirectory("./Upstart.config", buildOutputPath);
|
||||
|
||||
Gzip($"./BuildOutput/{netCoreFramework}/{runtimeId}", $"./{artifactsDirName}", "Jackett", "Experimental.Jackett.Binaries.LinuxAMD64.tar.gz");
|
||||
Gzip($"./BuildOutput/{netCoreFramework}/{runtimeId}", $"./{artifactsDirName}", "Jackett", "Experimental.Jackett.Binaries.LinuxAMDx64.tar.gz");
|
||||
});
|
||||
|
||||
Task("Package-DotNetCore-LinuxARM32")
|
||||
|
@ -297,7 +297,7 @@ Task("Windows-Environment")
|
|||
.IsDependentOn("Package-Windows-Full-Framework")
|
||||
.IsDependentOn("Package-Mono-Full-Framework")
|
||||
//.IsDependentOn("Package-DotNetCore-macOS")
|
||||
//.IsDependentOn("Package-DotNetCore-LinuxAMD64")
|
||||
//.IsDependentOn("Package-DotNetCore-LinuxAMDx64")
|
||||
//.IsDependentOn("Package-DotNetCore-LinuxARM32")
|
||||
//.IsDependentOn("Package-DotNetCore-LinuxARM64")
|
||||
.IsDependentOn("Appveyor-Push-Artifacts")
|
||||
|
@ -309,7 +309,7 @@ Task("Windows-Environment")
|
|||
|
||||
Task("Linux-Environment")
|
||||
.IsDependentOn("Package-DotNetCore-macOS")
|
||||
.IsDependentOn("Package-DotNetCore-LinuxAMD64")
|
||||
.IsDependentOn("Package-DotNetCore-LinuxAMDx64")
|
||||
.IsDependentOn("Package-DotNetCore-LinuxARM32")
|
||||
.IsDependentOn("Package-DotNetCore-LinuxARM64")
|
||||
.IsDependentOn("Appveyor-Push-Artifacts")
|
||||
|
|
|
@ -18,6 +18,7 @@
|
|||
<PackageReference Include="Microsoft.AspNetCore.WebUtilities" Version="2.2.0" />
|
||||
<PackageReference Include="Microsoft.CSharp" Version="4.5.0" />
|
||||
<PackageReference Include="MimeMapping" Version="1.0.1.12" />
|
||||
<PackageReference Include="Mono.Posix.NETStandard" Version="1.0.0" />
|
||||
<PackageReference Include="Newtonsoft.Json" Version="12.0.1" />
|
||||
<PackageReference Include="NLog" Version="4.5.11" />
|
||||
<PackageReference Include="SharpZipLib" Version="1.1.0" />
|
||||
|
|
|
@ -17,6 +17,8 @@ using Jackett.Common.Models.GitHub;
|
|||
using Jackett.Common.Services.Interfaces;
|
||||
using Jackett.Common.Utils;
|
||||
using Jackett.Common.Utils.Clients;
|
||||
using Mono.Posix;
|
||||
using Mono.Unix;
|
||||
using Newtonsoft.Json;
|
||||
using NLog;
|
||||
|
||||
|
@ -185,7 +187,7 @@ namespace Jackett.Common.Services
|
|||
|
||||
private string GetUpdaterPath(string tempDirectory)
|
||||
{
|
||||
if (variant == Variants.JackettVariant.CoreMacOs || variant == Variants.JackettVariant.CoreLinuxAmd64 ||
|
||||
if (variant == Variants.JackettVariant.CoreMacOs || variant == Variants.JackettVariant.CoreLinuxAmdx64 ||
|
||||
variant == Variants.JackettVariant.CoreLinuxArm32 || variant == Variants.JackettVariant.CoreLinuxArm64)
|
||||
{
|
||||
return Path.Combine(tempDirectory, "Jackett", "JackettUpdater");
|
||||
|
@ -294,6 +296,17 @@ namespace Jackett.Common.Services
|
|||
tarArchive.Close();
|
||||
gzipStream.Close();
|
||||
inStream.Close();
|
||||
|
||||
// When the files get extracted, the execute permission for jackett and JackettUpdater don't get carried across
|
||||
UnixFileInfo jackettFI = new UnixFileInfo(Path.Combine(tempDir, "/Jackett/jackett"))
|
||||
{
|
||||
FileAccessPermissions = FileAccessPermissions.UserReadWriteExecute | FileAccessPermissions.GroupRead | FileAccessPermissions.OtherRead
|
||||
};
|
||||
|
||||
UnixFileInfo jackettUpdaterFI = new UnixFileInfo(Path.Combine(tempDir + "/Jackett/JackettUpdater"))
|
||||
{
|
||||
FileAccessPermissions = FileAccessPermissions.UserReadWriteExecute | FileAccessPermissions.GroupRead | FileAccessPermissions.OtherRead
|
||||
};
|
||||
}
|
||||
|
||||
return tempDir;
|
||||
|
|
|
@ -14,7 +14,7 @@ namespace Jackett.Common.Utils
|
|||
Mono,
|
||||
CoreWindows,
|
||||
CoreMacOs,
|
||||
CoreLinuxAmd64,
|
||||
CoreLinuxAmdx64,
|
||||
CoreLinuxArm32,
|
||||
CoreLinuxArm64
|
||||
}
|
||||
|
@ -37,7 +37,7 @@ namespace Jackett.Common.Utils
|
|||
|
||||
if (RuntimeInformation.IsOSPlatform(OSPlatform.Linux) && RuntimeInformation.ProcessArchitecture == Architecture.X64)
|
||||
{
|
||||
return JackettVariant.CoreLinuxAmd64;
|
||||
return JackettVariant.CoreLinuxAmdx64;
|
||||
}
|
||||
|
||||
if (RuntimeInformation.IsOSPlatform(OSPlatform.Linux) && RuntimeInformation.ProcessArchitecture == Architecture.Arm)
|
||||
|
@ -88,9 +88,9 @@ namespace Jackett.Common.Utils
|
|||
{
|
||||
return "Jackett.Binaries.macOS.tar.gz";
|
||||
}
|
||||
case JackettVariant.CoreLinuxAmd64:
|
||||
case JackettVariant.CoreLinuxAmdx64:
|
||||
{
|
||||
return "Jackett.Binaries.LinuxAMD64.tar.gz";
|
||||
return "Jackett.Binaries.LinuxAMDx64.tar.gz";
|
||||
}
|
||||
case JackettVariant.CoreLinuxArm32:
|
||||
{
|
||||
|
|
|
@ -389,7 +389,7 @@ namespace Jackett.Updater
|
|||
|
||||
private string GetJackettConsolePath(string directoryPath)
|
||||
{
|
||||
if (variant == Variants.JackettVariant.CoreMacOs || variant == Variants.JackettVariant.CoreLinuxAmd64 ||
|
||||
if (variant == Variants.JackettVariant.CoreMacOs || variant == Variants.JackettVariant.CoreLinuxAmdx64 ||
|
||||
variant == Variants.JackettVariant.CoreLinuxArm32 || variant == Variants.JackettVariant.CoreLinuxArm64)
|
||||
{
|
||||
return Path.Combine(directoryPath, "jackett");
|
||||
|
|
Loading…
Reference in a new issue