mirror of
https://github.com/Ombi-app/Ombi.git
synced 2025-07-15 01:32:55 -07:00
commit
e9811b372e
11 changed files with 385 additions and 67 deletions
15
build.cake
15
build.cake
|
@ -161,7 +161,7 @@ Task("Publish")
|
||||||
.IsDependentOn("Publish-OSX")
|
.IsDependentOn("Publish-OSX")
|
||||||
.IsDependentOn("Publish-Linux")
|
.IsDependentOn("Publish-Linux")
|
||||||
.IsDependentOn("Publish-Linux-ARM")
|
.IsDependentOn("Publish-Linux-ARM")
|
||||||
//.IsDependentOn("Publish-Linux-ARM-64Bit")
|
.IsDependentOn("Publish-Linux-ARM-64Bit")
|
||||||
.IsDependentOn("Package");
|
.IsDependentOn("Package");
|
||||||
|
|
||||||
Task("Publish-Windows")
|
Task("Publish-Windows")
|
||||||
|
@ -172,6 +172,8 @@ Task("Publish-Windows")
|
||||||
|
|
||||||
DotNetCorePublish("./src/Ombi/Ombi.csproj", publishSettings);
|
DotNetCorePublish("./src/Ombi/Ombi.csproj", publishSettings);
|
||||||
CopyFile(buildDir + "/"+frameworkVer+"/win10-x64/Swagger.xml", buildDir + "/"+frameworkVer+"/win10-x64/published/Swagger.xml");
|
CopyFile(buildDir + "/"+frameworkVer+"/win10-x64/Swagger.xml", buildDir + "/"+frameworkVer+"/win10-x64/published/Swagger.xml");
|
||||||
|
|
||||||
|
publishSettings.OutputDirectory = Directory(buildDir) + Directory(frameworkVer +"/win10-x64/published/updater");
|
||||||
DotNetCorePublish("./src/Ombi.Updater/Ombi.Updater.csproj", publishSettings);
|
DotNetCorePublish("./src/Ombi.Updater/Ombi.Updater.csproj", publishSettings);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -183,6 +185,9 @@ Task("Publish-Windows-32bit")
|
||||||
|
|
||||||
DotNetCorePublish("./src/Ombi/Ombi.csproj", publishSettings);
|
DotNetCorePublish("./src/Ombi/Ombi.csproj", publishSettings);
|
||||||
CopyFile(buildDir + "/"+frameworkVer+"/win10-x86/Swagger.xml", buildDir + "/"+frameworkVer+"/win10-x86/published/Swagger.xml");
|
CopyFile(buildDir + "/"+frameworkVer+"/win10-x86/Swagger.xml", buildDir + "/"+frameworkVer+"/win10-x86/published/Swagger.xml");
|
||||||
|
|
||||||
|
|
||||||
|
publishSettings.OutputDirectory = Directory(buildDir) + Directory(frameworkVer +"/win10-x86/published/updater");
|
||||||
DotNetCorePublish("./src/Ombi.Updater/Ombi.Updater.csproj", publishSettings);
|
DotNetCorePublish("./src/Ombi.Updater/Ombi.Updater.csproj", publishSettings);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -194,6 +199,8 @@ Task("Publish-OSX")
|
||||||
|
|
||||||
DotNetCorePublish("./src/Ombi/Ombi.csproj", publishSettings);
|
DotNetCorePublish("./src/Ombi/Ombi.csproj", publishSettings);
|
||||||
CopyFile(buildDir + "/"+frameworkVer+"/osx-x64/Swagger.xml", buildDir + "/"+frameworkVer+"/osx-x64/published/Swagger.xml");
|
CopyFile(buildDir + "/"+frameworkVer+"/osx-x64/Swagger.xml", buildDir + "/"+frameworkVer+"/osx-x64/published/Swagger.xml");
|
||||||
|
|
||||||
|
publishSettings.OutputDirectory = Directory(buildDir) + Directory(frameworkVer +"/osx-x64/published/updater");
|
||||||
DotNetCorePublish("./src/Ombi.Updater/Ombi.Updater.csproj", publishSettings);
|
DotNetCorePublish("./src/Ombi.Updater/Ombi.Updater.csproj", publishSettings);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -205,6 +212,8 @@ Task("Publish-Linux")
|
||||||
|
|
||||||
DotNetCorePublish("./src/Ombi/Ombi.csproj", publishSettings);
|
DotNetCorePublish("./src/Ombi/Ombi.csproj", publishSettings);
|
||||||
CopyFile(buildDir + "/"+frameworkVer+"/linux-x64/Swagger.xml", buildDir + "/"+frameworkVer+"/linux-x64/published/Swagger.xml");
|
CopyFile(buildDir + "/"+frameworkVer+"/linux-x64/Swagger.xml", buildDir + "/"+frameworkVer+"/linux-x64/published/Swagger.xml");
|
||||||
|
|
||||||
|
publishSettings.OutputDirectory = Directory(buildDir) + Directory(frameworkVer +"/linux-x64/published/updater");
|
||||||
DotNetCorePublish("./src/Ombi.Updater/Ombi.Updater.csproj", publishSettings);
|
DotNetCorePublish("./src/Ombi.Updater/Ombi.Updater.csproj", publishSettings);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -218,6 +227,8 @@ Task("Publish-Linux-ARM")
|
||||||
CopyFile(
|
CopyFile(
|
||||||
buildDir + "/"+frameworkVer+"/linux-arm/Swagger.xml",
|
buildDir + "/"+frameworkVer+"/linux-arm/Swagger.xml",
|
||||||
buildDir + "/"+frameworkVer+"/linux-arm/published/Swagger.xml");
|
buildDir + "/"+frameworkVer+"/linux-arm/published/Swagger.xml");
|
||||||
|
|
||||||
|
publishSettings.OutputDirectory = Directory(buildDir) + Directory(frameworkVer +"/linux-arm/published/updater");
|
||||||
DotNetCorePublish("./src/Ombi.Updater/Ombi.Updater.csproj", publishSettings);
|
DotNetCorePublish("./src/Ombi.Updater/Ombi.Updater.csproj", publishSettings);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -231,6 +242,8 @@ Task("Publish-Linux-ARM-64Bit")
|
||||||
CopyFile(
|
CopyFile(
|
||||||
buildDir + "/"+frameworkVer+"/linux-arm64/Swagger.xml",
|
buildDir + "/"+frameworkVer+"/linux-arm64/Swagger.xml",
|
||||||
buildDir + "/"+frameworkVer+"/linux-arm64/published/Swagger.xml");
|
buildDir + "/"+frameworkVer+"/linux-arm64/published/Swagger.xml");
|
||||||
|
|
||||||
|
publishSettings.OutputDirectory = Directory(buildDir) + Directory(frameworkVer +"/linux-arm64/published/updater");
|
||||||
DotNetCorePublish("./src/Ombi.Updater/Ombi.Updater.csproj", publishSettings);
|
DotNetCorePublish("./src/Ombi.Updater/Ombi.Updater.csproj", publishSettings);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
291
package-lock.json
generated
Normal file
291
package-lock.json
generated
Normal file
|
@ -0,0 +1,291 @@
|
||||||
|
{
|
||||||
|
"requires": true,
|
||||||
|
"lockfileVersion": 1,
|
||||||
|
"dependencies": {
|
||||||
|
"ansi-regex": {
|
||||||
|
"version": "2.1.1",
|
||||||
|
"resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz",
|
||||||
|
"integrity": "sha1-w7M6te42DYbg5ijwRorn7yfWVN8="
|
||||||
|
},
|
||||||
|
"ansi-styles": {
|
||||||
|
"version": "2.2.1",
|
||||||
|
"resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-2.2.1.tgz",
|
||||||
|
"integrity": "sha1-tDLdM1i2NM914eRmQ2gkBTPB3b4="
|
||||||
|
},
|
||||||
|
"argparse": {
|
||||||
|
"version": "1.0.10",
|
||||||
|
"resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz",
|
||||||
|
"integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==",
|
||||||
|
"requires": {
|
||||||
|
"sprintf-js": "1.0.3"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"babel-code-frame": {
|
||||||
|
"version": "6.26.0",
|
||||||
|
"resolved": "https://registry.npmjs.org/babel-code-frame/-/babel-code-frame-6.26.0.tgz",
|
||||||
|
"integrity": "sha1-Y/1D99weO7fONZR9uP42mj9Yx0s=",
|
||||||
|
"requires": {
|
||||||
|
"chalk": "1.1.3",
|
||||||
|
"esutils": "2.0.2",
|
||||||
|
"js-tokens": "3.0.2"
|
||||||
|
},
|
||||||
|
"dependencies": {
|
||||||
|
"chalk": {
|
||||||
|
"version": "1.1.3",
|
||||||
|
"resolved": "https://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz",
|
||||||
|
"integrity": "sha1-qBFcVeSnAv5NFQq9OHKCKn4J/Jg=",
|
||||||
|
"requires": {
|
||||||
|
"ansi-styles": "2.2.1",
|
||||||
|
"escape-string-regexp": "1.0.5",
|
||||||
|
"has-ansi": "2.0.0",
|
||||||
|
"strip-ansi": "3.0.1",
|
||||||
|
"supports-color": "2.0.0"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"balanced-match": {
|
||||||
|
"version": "1.0.0",
|
||||||
|
"resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.0.tgz",
|
||||||
|
"integrity": "sha1-ibTRmasr7kneFk6gK4nORi1xt2c="
|
||||||
|
},
|
||||||
|
"brace-expansion": {
|
||||||
|
"version": "1.1.11",
|
||||||
|
"resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz",
|
||||||
|
"integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==",
|
||||||
|
"requires": {
|
||||||
|
"balanced-match": "1.0.0",
|
||||||
|
"concat-map": "0.0.1"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"builtin-modules": {
|
||||||
|
"version": "1.1.1",
|
||||||
|
"resolved": "https://registry.npmjs.org/builtin-modules/-/builtin-modules-1.1.1.tgz",
|
||||||
|
"integrity": "sha1-Jw8HbFpywC9bZaR9+Uxf46J4iS8="
|
||||||
|
},
|
||||||
|
"chalk": {
|
||||||
|
"version": "2.4.1",
|
||||||
|
"resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.1.tgz",
|
||||||
|
"integrity": "sha512-ObN6h1v2fTJSmUXoS3nMQ92LbDK9be4TV+6G+omQlGJFdcUX5heKi1LZ1YnRMIgwTLEj3E24bT6tYni50rlCfQ==",
|
||||||
|
"requires": {
|
||||||
|
"ansi-styles": "3.2.1",
|
||||||
|
"escape-string-regexp": "1.0.5",
|
||||||
|
"supports-color": "5.4.0"
|
||||||
|
},
|
||||||
|
"dependencies": {
|
||||||
|
"ansi-styles": {
|
||||||
|
"version": "3.2.1",
|
||||||
|
"resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz",
|
||||||
|
"integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==",
|
||||||
|
"requires": {
|
||||||
|
"color-convert": "1.9.1"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"supports-color": {
|
||||||
|
"version": "5.4.0",
|
||||||
|
"resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.4.0.tgz",
|
||||||
|
"integrity": "sha512-zjaXglF5nnWpsq470jSv6P9DwPvgLkuapYmfDm3JWOm0vkNTVF2tI4UrN2r6jH1qM/uc/WtxYY1hYoA2dOKj5w==",
|
||||||
|
"requires": {
|
||||||
|
"has-flag": "3.0.0"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"color-convert": {
|
||||||
|
"version": "1.9.1",
|
||||||
|
"resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.1.tgz",
|
||||||
|
"integrity": "sha512-mjGanIiwQJskCC18rPR6OmrZ6fm2Lc7PeGFYwCmy5J34wC6F1PzdGL6xeMfmgicfYcNLGuVFA3WzXtIDCQSZxQ==",
|
||||||
|
"requires": {
|
||||||
|
"color-name": "1.1.3"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"color-name": {
|
||||||
|
"version": "1.1.3",
|
||||||
|
"resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz",
|
||||||
|
"integrity": "sha1-p9BVi9icQveV3UIyj3QIMcpTvCU="
|
||||||
|
},
|
||||||
|
"commander": {
|
||||||
|
"version": "2.15.1",
|
||||||
|
"resolved": "https://registry.npmjs.org/commander/-/commander-2.15.1.tgz",
|
||||||
|
"integrity": "sha512-VlfT9F3V0v+jr4yxPc5gg9s62/fIVWsd2Bk2iD435um1NlGMYdVCq+MjcXnhYq2icNOizHr1kK+5TI6H0Hy0ag=="
|
||||||
|
},
|
||||||
|
"concat-map": {
|
||||||
|
"version": "0.0.1",
|
||||||
|
"resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz",
|
||||||
|
"integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s="
|
||||||
|
},
|
||||||
|
"diff": {
|
||||||
|
"version": "3.5.0",
|
||||||
|
"resolved": "https://registry.npmjs.org/diff/-/diff-3.5.0.tgz",
|
||||||
|
"integrity": "sha512-A46qtFgd+g7pDZinpnwiRJtxbC1hpgf0uzP3iG89scHk0AUC7A1TGxf5OiiOUv/JMZR8GOt8hL900hV0bOy5xA=="
|
||||||
|
},
|
||||||
|
"escape-string-regexp": {
|
||||||
|
"version": "1.0.5",
|
||||||
|
"resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz",
|
||||||
|
"integrity": "sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ="
|
||||||
|
},
|
||||||
|
"esprima": {
|
||||||
|
"version": "4.0.0",
|
||||||
|
"resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.0.tgz",
|
||||||
|
"integrity": "sha512-oftTcaMu/EGrEIu904mWteKIv8vMuOgGYo7EhVJJN00R/EED9DCua/xxHRdYnKtcECzVg7xOWhflvJMnqcFZjw=="
|
||||||
|
},
|
||||||
|
"esutils": {
|
||||||
|
"version": "2.0.2",
|
||||||
|
"resolved": "https://registry.npmjs.org/esutils/-/esutils-2.0.2.tgz",
|
||||||
|
"integrity": "sha1-Cr9PHKpbyx96nYrMbepPqqBLrJs="
|
||||||
|
},
|
||||||
|
"fs.realpath": {
|
||||||
|
"version": "1.0.0",
|
||||||
|
"resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz",
|
||||||
|
"integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8="
|
||||||
|
},
|
||||||
|
"glob": {
|
||||||
|
"version": "7.1.2",
|
||||||
|
"resolved": "https://registry.npmjs.org/glob/-/glob-7.1.2.tgz",
|
||||||
|
"integrity": "sha512-MJTUg1kjuLeQCJ+ccE4Vpa6kKVXkPYJ2mOCQyUuKLcLQsdrMCpBPUi8qVE6+YuaJkozeA9NusTAw3hLr8Xe5EQ==",
|
||||||
|
"requires": {
|
||||||
|
"fs.realpath": "1.0.0",
|
||||||
|
"inflight": "1.0.6",
|
||||||
|
"inherits": "2.0.3",
|
||||||
|
"minimatch": "3.0.4",
|
||||||
|
"once": "1.4.0",
|
||||||
|
"path-is-absolute": "1.0.1"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"has-ansi": {
|
||||||
|
"version": "2.0.0",
|
||||||
|
"resolved": "https://registry.npmjs.org/has-ansi/-/has-ansi-2.0.0.tgz",
|
||||||
|
"integrity": "sha1-NPUEnOHs3ysGSa8+8k5F7TVBbZE=",
|
||||||
|
"requires": {
|
||||||
|
"ansi-regex": "2.1.1"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"has-flag": {
|
||||||
|
"version": "3.0.0",
|
||||||
|
"resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz",
|
||||||
|
"integrity": "sha1-tdRU3CGZriJWmfNGfloH87lVuv0="
|
||||||
|
},
|
||||||
|
"inflight": {
|
||||||
|
"version": "1.0.6",
|
||||||
|
"resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz",
|
||||||
|
"integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=",
|
||||||
|
"requires": {
|
||||||
|
"once": "1.4.0",
|
||||||
|
"wrappy": "1.0.2"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"inherits": {
|
||||||
|
"version": "2.0.3",
|
||||||
|
"resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.3.tgz",
|
||||||
|
"integrity": "sha1-Yzwsg+PaQqUC9SRmAiSA9CCCYd4="
|
||||||
|
},
|
||||||
|
"js-tokens": {
|
||||||
|
"version": "3.0.2",
|
||||||
|
"resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-3.0.2.tgz",
|
||||||
|
"integrity": "sha1-mGbfOVECEw449/mWvOtlRDIJwls="
|
||||||
|
},
|
||||||
|
"js-yaml": {
|
||||||
|
"version": "3.12.0",
|
||||||
|
"resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.12.0.tgz",
|
||||||
|
"integrity": "sha512-PIt2cnwmPfL4hKNwqeiuz4bKfnzHTBv6HyVgjahA6mPLwPDzjDWrplJBMjHUFxku/N3FlmrbyPclad+I+4mJ3A==",
|
||||||
|
"requires": {
|
||||||
|
"argparse": "1.0.10",
|
||||||
|
"esprima": "4.0.0"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"minimatch": {
|
||||||
|
"version": "3.0.4",
|
||||||
|
"resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz",
|
||||||
|
"integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==",
|
||||||
|
"requires": {
|
||||||
|
"brace-expansion": "1.1.11"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"once": {
|
||||||
|
"version": "1.4.0",
|
||||||
|
"resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz",
|
||||||
|
"integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=",
|
||||||
|
"requires": {
|
||||||
|
"wrappy": "1.0.2"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"path-is-absolute": {
|
||||||
|
"version": "1.0.1",
|
||||||
|
"resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz",
|
||||||
|
"integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18="
|
||||||
|
},
|
||||||
|
"path-parse": {
|
||||||
|
"version": "1.0.5",
|
||||||
|
"resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.5.tgz",
|
||||||
|
"integrity": "sha1-PBrfhx6pzWyUMbbqK9dKD/BVxME="
|
||||||
|
},
|
||||||
|
"resolve": {
|
||||||
|
"version": "1.7.1",
|
||||||
|
"resolved": "https://registry.npmjs.org/resolve/-/resolve-1.7.1.tgz",
|
||||||
|
"integrity": "sha512-c7rwLofp8g1U+h1KNyHL/jicrKg1Ek4q+Lr33AL65uZTinUZHe30D5HlyN5V9NW0JX1D5dXQ4jqW5l7Sy/kGfw==",
|
||||||
|
"requires": {
|
||||||
|
"path-parse": "1.0.5"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"semver": {
|
||||||
|
"version": "5.5.0",
|
||||||
|
"resolved": "https://registry.npmjs.org/semver/-/semver-5.5.0.tgz",
|
||||||
|
"integrity": "sha512-4SJ3dm0WAwWy/NVeioZh5AntkdJoWKxHxcmyP622fOkgHa4z3R0TdBJICINyaSDE6uNwVc8gZr+ZinwZAH4xIA=="
|
||||||
|
},
|
||||||
|
"sprintf-js": {
|
||||||
|
"version": "1.0.3",
|
||||||
|
"resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz",
|
||||||
|
"integrity": "sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw="
|
||||||
|
},
|
||||||
|
"strip-ansi": {
|
||||||
|
"version": "3.0.1",
|
||||||
|
"resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz",
|
||||||
|
"integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=",
|
||||||
|
"requires": {
|
||||||
|
"ansi-regex": "2.1.1"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"supports-color": {
|
||||||
|
"version": "2.0.0",
|
||||||
|
"resolved": "https://registry.npmjs.org/supports-color/-/supports-color-2.0.0.tgz",
|
||||||
|
"integrity": "sha1-U10EXOa2Nj+kARcIRimZXp3zJMc="
|
||||||
|
},
|
||||||
|
"tslib": {
|
||||||
|
"version": "1.9.2",
|
||||||
|
"resolved": "https://registry.npmjs.org/tslib/-/tslib-1.9.2.tgz",
|
||||||
|
"integrity": "sha512-AVP5Xol3WivEr7hnssHDsaM+lVrVXWUvd1cfXTRkTj80b//6g2wIFEH6hZG0muGZRnHGrfttpdzRk3YlBkWjKw=="
|
||||||
|
},
|
||||||
|
"tslint": {
|
||||||
|
"version": "5.10.0",
|
||||||
|
"resolved": "https://registry.npmjs.org/tslint/-/tslint-5.10.0.tgz",
|
||||||
|
"integrity": "sha1-EeJrzLiK+gLdDZlWyuPUVAtfVMM=",
|
||||||
|
"requires": {
|
||||||
|
"babel-code-frame": "6.26.0",
|
||||||
|
"builtin-modules": "1.1.1",
|
||||||
|
"chalk": "2.4.1",
|
||||||
|
"commander": "2.15.1",
|
||||||
|
"diff": "3.5.0",
|
||||||
|
"glob": "7.1.2",
|
||||||
|
"js-yaml": "3.12.0",
|
||||||
|
"minimatch": "3.0.4",
|
||||||
|
"resolve": "1.7.1",
|
||||||
|
"semver": "5.5.0",
|
||||||
|
"tslib": "1.9.2",
|
||||||
|
"tsutils": "2.27.1"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"tsutils": {
|
||||||
|
"version": "2.27.1",
|
||||||
|
"resolved": "https://registry.npmjs.org/tsutils/-/tsutils-2.27.1.tgz",
|
||||||
|
"integrity": "sha512-AE/7uzp32MmaHvNNFES85hhUDHFdFZp6OAiZcd6y4ZKKIg6orJTm8keYWBhIhrJQH3a4LzNKat7ZPXZt5aTf6w==",
|
||||||
|
"requires": {
|
||||||
|
"tslib": "1.9.2"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"wrappy": {
|
||||||
|
"version": "1.0.2",
|
||||||
|
"resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz",
|
||||||
|
"integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8="
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
|
@ -72,7 +72,7 @@ namespace Ombi.Schedule.Jobs.Ombi
|
||||||
Logger.LogDebug(LoggingEvents.Updater, "Starting Update job");
|
Logger.LogDebug(LoggingEvents.Updater, "Starting Update job");
|
||||||
|
|
||||||
var settings = await Settings.GetSettingsAsync();
|
var settings = await Settings.GetSettingsAsync();
|
||||||
if (!settings.AutoUpdateEnabled)
|
if (!settings.AutoUpdateEnabled && !settings.TestMode)
|
||||||
{
|
{
|
||||||
Logger.LogDebug(LoggingEvents.Updater, "Auto update is not enabled");
|
Logger.LogDebug(LoggingEvents.Updater, "Auto update is not enabled");
|
||||||
return;
|
return;
|
||||||
|
@ -83,7 +83,7 @@ namespace Ombi.Schedule.Jobs.Ombi
|
||||||
|
|
||||||
var productVersion = AssemblyHelper.GetRuntimeVersion();
|
var productVersion = AssemblyHelper.GetRuntimeVersion();
|
||||||
Logger.LogDebug(LoggingEvents.Updater, "Product Version {0}", productVersion);
|
Logger.LogDebug(LoggingEvents.Updater, "Product Version {0}", productVersion);
|
||||||
|
var serverVersion = string.Empty;
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
var productArray = GetVersion();
|
var productArray = GetVersion();
|
||||||
|
@ -96,13 +96,17 @@ namespace Ombi.Schedule.Jobs.Ombi
|
||||||
Logger.LogDebug(LoggingEvents.Updater, "Branch {0}", branch);
|
Logger.LogDebug(LoggingEvents.Updater, "Branch {0}", branch);
|
||||||
|
|
||||||
Logger.LogDebug(LoggingEvents.Updater, "Looking for updates now");
|
Logger.LogDebug(LoggingEvents.Updater, "Looking for updates now");
|
||||||
|
//TODO this fails because the branch = featureupdater when it should be feature/updater
|
||||||
var updates = await Processor.Process(branch);
|
var updates = await Processor.Process(branch);
|
||||||
Logger.LogDebug(LoggingEvents.Updater, "Updates: {0}", updates);
|
Logger.LogDebug(LoggingEvents.Updater, "Updates: {0}", updates);
|
||||||
var serverVersion = updates.UpdateVersionString;
|
|
||||||
|
|
||||||
|
serverVersion = updates.UpdateVersionString;
|
||||||
|
|
||||||
Logger.LogDebug(LoggingEvents.Updater, "Service Version {0}", updates.UpdateVersionString);
|
Logger.LogDebug(LoggingEvents.Updater, "Service Version {0}", updates.UpdateVersionString);
|
||||||
|
|
||||||
if (!serverVersion.Equals(version, StringComparison.CurrentCultureIgnoreCase))
|
|
||||||
|
if (!serverVersion.Equals(version, StringComparison.CurrentCultureIgnoreCase) || settings.TestMode)
|
||||||
{
|
{
|
||||||
// Let's download the correct zip
|
// Let's download the correct zip
|
||||||
var desc = RuntimeInformation.OSDescription;
|
var desc = RuntimeInformation.OSDescription;
|
||||||
|
@ -135,7 +139,8 @@ namespace Ombi.Schedule.Jobs.Ombi
|
||||||
if (process == Architecture.Arm)
|
if (process == Architecture.Arm)
|
||||||
{
|
{
|
||||||
download = updates.Downloads.FirstOrDefault(x => x.Name.Contains("arm.", CompareOptions.IgnoreCase));
|
download = updates.Downloads.FirstOrDefault(x => x.Name.Contains("arm.", CompareOptions.IgnoreCase));
|
||||||
} else if (process == Architecture.Arm64)
|
}
|
||||||
|
else if (process == Architecture.Arm64)
|
||||||
{
|
{
|
||||||
download = updates.Downloads.FirstOrDefault(x => x.Name.Contains("arm64.", CompareOptions.IgnoreCase));
|
download = updates.Downloads.FirstOrDefault(x => x.Name.Contains("arm64.", CompareOptions.IgnoreCase));
|
||||||
}
|
}
|
||||||
|
@ -206,33 +211,35 @@ namespace Ombi.Schedule.Jobs.Ombi
|
||||||
updaterExtension = ".exe";
|
updaterExtension = ".exe";
|
||||||
}
|
}
|
||||||
var updaterFile = Path.Combine(Path.GetDirectoryName(Assembly.GetEntryAssembly().Location),
|
var updaterFile = Path.Combine(Path.GetDirectoryName(Assembly.GetEntryAssembly().Location),
|
||||||
"TempUpdate", $"Ombi.Updater{updaterExtension}");
|
"TempUpdate", "updater", $"Ombi.Updater{updaterExtension}");
|
||||||
|
|
||||||
// Make sure the file is an executable
|
// Make sure the file is an executable
|
||||||
ExecLinuxCommand($"chmod +x {updaterFile}");
|
//ExecLinuxCommand($"chmod +x {updaterFile}");
|
||||||
|
|
||||||
|
|
||||||
// There must be an update
|
// There must be an update
|
||||||
var start = new ProcessStartInfo
|
var start = new ProcessStartInfo
|
||||||
{
|
{
|
||||||
UseShellExecute = true,
|
UseShellExecute = false,
|
||||||
CreateNoWindow = false, // Ignored if UseShellExecute is set to true
|
CreateNoWindow = true, // Ignored if UseShellExecute is set to true
|
||||||
FileName = updaterFile,
|
FileName = updaterFile,
|
||||||
Arguments = GetArgs(settings),
|
Arguments = GetArgs(settings),
|
||||||
WorkingDirectory = Path.Combine(Path.GetDirectoryName(Assembly.GetEntryAssembly().Location), "TempUpdate"),
|
WorkingDirectory = Path.Combine(Path.GetDirectoryName(Assembly.GetEntryAssembly().Location), "TempUpdate"),
|
||||||
};
|
};
|
||||||
if (settings.Username.HasValue())
|
//if (settings.Username.HasValue())
|
||||||
|
//{
|
||||||
|
// start.UserName = settings.Username;
|
||||||
|
//}
|
||||||
|
//if (settings.Password.HasValue())
|
||||||
|
//{
|
||||||
|
// start.Password = settings.Password.ToSecureString();
|
||||||
|
//}
|
||||||
|
using (var proc = new Process { StartInfo = start })
|
||||||
{
|
{
|
||||||
start.UserName = settings.Username;
|
proc.Start();
|
||||||
}
|
}
|
||||||
if (settings.Password.HasValue())
|
|
||||||
{
|
|
||||||
start.Password = settings.Password.ToSecureString();
|
|
||||||
}
|
|
||||||
var proc = new Process { StartInfo = start };
|
|
||||||
|
|
||||||
|
|
||||||
proc.Start();
|
|
||||||
|
|
||||||
Logger.LogDebug(LoggingEvents.Updater, "Bye bye");
|
Logger.LogDebug(LoggingEvents.Updater, "Bye bye");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -254,10 +261,10 @@ namespace Ombi.Schedule.Jobs.Ombi
|
||||||
|
|
||||||
var sb = new StringBuilder();
|
var sb = new StringBuilder();
|
||||||
sb.Append($"--applicationPath \"{currentLocation}\" --processname \"{processName}\" ");
|
sb.Append($"--applicationPath \"{currentLocation}\" --processname \"{processName}\" ");
|
||||||
if (settings.WindowsService)
|
//if (settings.WindowsService)
|
||||||
{
|
//{
|
||||||
sb.Append($"--windowsServiceName \"{settings.WindowsServiceName}\" ");
|
// sb.Append($"--windowsServiceName \"{settings.WindowsServiceName}\" ");
|
||||||
}
|
//}
|
||||||
var sb2 = new StringBuilder();
|
var sb2 = new StringBuilder();
|
||||||
if (url?.Value.HasValue() ?? false)
|
if (url?.Value.HasValue() ?? false)
|
||||||
{
|
{
|
||||||
|
|
|
@ -10,5 +10,6 @@
|
||||||
public string ScriptLocation { get; set; }
|
public string ScriptLocation { get; set; }
|
||||||
public string WindowsServiceName { get; set; }
|
public string WindowsServiceName { get; set; }
|
||||||
public bool WindowsService { get; set; }
|
public bool WindowsService { get; set; }
|
||||||
|
public bool TestMode { get; set; }
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -11,7 +11,7 @@ namespace Ombi.Updater
|
||||||
ProcessInfo GetCurrentProcess();
|
ProcessInfo GetCurrentProcess();
|
||||||
int GetCurrentProcessId();
|
int GetCurrentProcessId();
|
||||||
ProcessInfo GetProcessById(int id);
|
ProcessInfo GetProcessById(int id);
|
||||||
void Kill(StartupOptions opts);
|
bool Kill(StartupOptions opts);
|
||||||
void KillAll(string processName);
|
void KillAll(string processName);
|
||||||
void SetPriority(int processId, ProcessPriorityClass priority);
|
void SetPriority(int processId, ProcessPriorityClass priority);
|
||||||
void WaitForExit(Process process);
|
void WaitForExit(Process process);
|
||||||
|
|
|
@ -22,29 +22,23 @@ namespace Ombi.Updater
|
||||||
{
|
{
|
||||||
// Kill Ombi Process
|
// Kill Ombi Process
|
||||||
var p = new ProcessProvider();
|
var p = new ProcessProvider();
|
||||||
|
bool killed = false;
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
|
|
||||||
|
|
||||||
p.Kill(opt);
|
killed = p.Kill(opt);
|
||||||
}
|
}
|
||||||
catch (Exception e)
|
catch (Exception e)
|
||||||
{
|
{
|
||||||
Console.WriteLine(e);
|
Console.WriteLine(e);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Make sure the process has been killed
|
if (!killed)
|
||||||
while (p.FindProcessByName(opt.ProcessName).Any())
|
|
||||||
{
|
{
|
||||||
Thread.Sleep(500);
|
|
||||||
_log.LogDebug("Found another process called {0}, KILLING!", opt.ProcessName);
|
_log.LogDebug("Couldn't kill the ombi process");
|
||||||
var proc = p.FindProcessByName(opt.ProcessName).FirstOrDefault();
|
return;
|
||||||
if (proc != null)
|
|
||||||
{
|
|
||||||
_log.LogDebug($"[{proc.Id}] - {proc.Name} - Path: {proc.StartPath}");
|
|
||||||
opt.OmbiProcessId = proc.Id;
|
|
||||||
p.Kill(opt);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
_log.LogDebug("Starting to move the files");
|
_log.LogDebug("Starting to move the files");
|
||||||
|
@ -111,21 +105,23 @@ namespace Ombi.Updater
|
||||||
var location = System.Reflection.Assembly.GetEntryAssembly().Location;
|
var location = System.Reflection.Assembly.GetEntryAssembly().Location;
|
||||||
location = Path.GetDirectoryName(location);
|
location = Path.GetDirectoryName(location);
|
||||||
_log.LogDebug("We are currently in dir {0}", location);
|
_log.LogDebug("We are currently in dir {0}", location);
|
||||||
|
var updatedLocation = Directory.GetParent(location).FullName;
|
||||||
|
_log.LogDebug("The files are in {0}", updatedLocation); // Since the updater is a folder deeper
|
||||||
_log.LogDebug("Ombi is installed at {0}", options.ApplicationPath);
|
_log.LogDebug("Ombi is installed at {0}", options.ApplicationPath);
|
||||||
|
|
||||||
//Now Create all of the directories
|
//Now Create all of the directories
|
||||||
foreach (string dirPath in Directory.GetDirectories(location, "*",
|
foreach (string dirPath in Directory.GetDirectories(updatedLocation, "*",
|
||||||
SearchOption.AllDirectories))
|
SearchOption.AllDirectories))
|
||||||
{
|
{
|
||||||
var newDir = dirPath.Replace(location, options.ApplicationPath);
|
var newDir = dirPath.Replace(updatedLocation, options.ApplicationPath);
|
||||||
Directory.CreateDirectory(newDir);
|
Directory.CreateDirectory(newDir);
|
||||||
_log.LogDebug("Created dir {0}", newDir);
|
_log.LogDebug("Created dir {0}", newDir);
|
||||||
}
|
}
|
||||||
//Copy all the files & Replaces any files with the same name
|
//Copy all the files & Replaces any files with the same name
|
||||||
foreach (string currentPath in Directory.GetFiles(location, "*.*",
|
foreach (string currentPath in Directory.GetFiles(updatedLocation, "*.*",
|
||||||
SearchOption.AllDirectories))
|
SearchOption.AllDirectories))
|
||||||
{
|
{
|
||||||
var newFile = currentPath.Replace(location, options.ApplicationPath);
|
var newFile = currentPath.Replace(updatedLocation, options.ApplicationPath);
|
||||||
File.Copy(currentPath, newFile, true);
|
File.Copy(currentPath, newFile, true);
|
||||||
_log.LogDebug("Replaced file {0}", newFile);
|
_log.LogDebug("Replaced file {0}", newFile);
|
||||||
}
|
}
|
||||||
|
|
|
@ -73,33 +73,32 @@ namespace Ombi.Updater
|
||||||
process.PriorityClass = priority;
|
process.PriorityClass = priority;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void Kill(StartupOptions opts)
|
public bool Kill(StartupOptions opts)
|
||||||
{
|
{
|
||||||
if (opts.IsWindowsService)
|
//if (opts.IsWindowsService)
|
||||||
{
|
//{
|
||||||
Console.WriteLine("Stopping Service {0}", opts.WindowsServiceName);
|
// Console.WriteLine("Stopping Service {0}", opts.WindowsServiceName);
|
||||||
var process = new Process();
|
// var process = new Process();
|
||||||
var startInfo =
|
// var startInfo =
|
||||||
new ProcessStartInfo
|
// new ProcessStartInfo
|
||||||
{
|
// {
|
||||||
WindowStyle = ProcessWindowStyle.Hidden,
|
// WindowStyle = ProcessWindowStyle.Hidden,
|
||||||
FileName = "cmd.exe",
|
// FileName = "cmd.exe",
|
||||||
Arguments = $"/C net stop \"{opts.WindowsServiceName}\""
|
// Arguments = $"/C net stop \"{opts.WindowsServiceName}\""
|
||||||
};
|
// };
|
||||||
process.StartInfo = startInfo;
|
// process.StartInfo = startInfo;
|
||||||
process.Start();
|
// process.Start();
|
||||||
}
|
//}
|
||||||
else
|
//else
|
||||||
{
|
//{
|
||||||
var process = Process.GetProcesses().FirstOrDefault(p => p.ProcessName == opts.ProcessName);
|
var process = Process.GetProcesses().FirstOrDefault(p => p.ProcessName == opts.ProcessName);
|
||||||
|
|
||||||
if (process == null)
|
if (process == null)
|
||||||
{
|
{
|
||||||
Console.WriteLine("Cannot find process with name: {0}", opts.ProcessName);
|
Console.WriteLine("Cannot find process with name: {0}", opts.ProcessName);
|
||||||
return;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
process.Refresh();
|
|
||||||
|
|
||||||
if (process.Id > 0)
|
if (process.Id > 0)
|
||||||
{
|
{
|
||||||
|
@ -108,8 +107,12 @@ namespace Ombi.Updater
|
||||||
Console.WriteLine("[{0}]: Waiting for exit", process.Id);
|
Console.WriteLine("[{0}]: Waiting for exit", process.Id);
|
||||||
process.WaitForExit();
|
process.WaitForExit();
|
||||||
Console.WriteLine("[{0}]: Process terminated successfully", process.Id);
|
Console.WriteLine("[{0}]: Process terminated successfully", process.Id);
|
||||||
|
|
||||||
|
return true;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
return false;
|
||||||
|
//}
|
||||||
}
|
}
|
||||||
|
|
||||||
public void KillAll(string processName)
|
public void KillAll(string processName)
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
"profiles": {
|
"profiles": {
|
||||||
"Ombi.Updater": {
|
"Ombi.Updater": {
|
||||||
"commandName": "Project",
|
"commandName": "Project",
|
||||||
"commandLineArgs": "--applicationPath \\\"C:\\\\Users\\\\Jamie\\\\Source\\\\Repos\\\\Ombi\\\\src\\\\Ombi\\\\bin\\\\Debug\\\\netcoreapp2.0\\\" --processname \\\"Ombi\\\" --startupArgs http://*:5000"
|
"commandLineArgs": "--applicationPath \"C:\\_git\\ombi\\src\\Ombi.Updater\\bin\\Debug\\netcoreapp2.0\" --processname \"Ombi\""
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -27,6 +27,7 @@ export interface IUpdateSettings extends ISettings {
|
||||||
windowsService: boolean;
|
windowsService: boolean;
|
||||||
windowsServiceName: string;
|
windowsServiceName: string;
|
||||||
isWindows: boolean;
|
isWindows: boolean;
|
||||||
|
testMode: boolean;
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface IEmbySettings extends ISettings {
|
export interface IEmbySettings extends ISettings {
|
||||||
|
|
|
@ -5,8 +5,8 @@
|
||||||
<fieldset>
|
<fieldset>
|
||||||
<legend>Update Settings</legend>
|
<legend>Update Settings</legend>
|
||||||
<div class="form-group" style="float: right">
|
<div class="form-group" style="float: right">
|
||||||
<div *ngIf="updateAvailable">
|
<div *ngIf="updateAvailable || form.controls['testMode'].value">
|
||||||
<button (click)="update()" [disabled]="!enableUpdateButton" class="btn btn-success-outline">Update</button>
|
<button (click)="update()" [disabled]="!enableUpdateButton || !form.controls['testMode'].value" class="btn btn-success-outline">Update</button>
|
||||||
</div>
|
</div>
|
||||||
<div *ngIf="!updateAvailable">
|
<div *ngIf="!updateAvailable">
|
||||||
<button (click)="checkForUpdate()" class="btn btn-primary-outline">Check For Update</button>
|
<button (click)="checkForUpdate()" class="btn btn-primary-outline">Check For Update</button>
|
||||||
|
@ -19,8 +19,13 @@
|
||||||
<input type="checkbox" id="autoUpdateEnabled" formControlName="autoUpdateEnabled">
|
<input type="checkbox" id="autoUpdateEnabled" formControlName="autoUpdateEnabled">
|
||||||
<label for="autoUpdateEnabled">Enable Automatic Update</label>
|
<label for="autoUpdateEnabled">Enable Automatic Update</label>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
<!-- <div class="form-group">
|
||||||
|
<div class="checkbox">
|
||||||
|
<input type="checkbox" id="testMode" formControlName="testMode">
|
||||||
|
<label for="testMode">Test Mode</label>
|
||||||
|
</div>
|
||||||
|
</div> -->
|
||||||
<div class="form-group" *ngIf="isWindows">
|
<div class="form-group" *ngIf="isWindows">
|
||||||
<div class="checkbox">
|
<div class="checkbox">
|
||||||
<input type="checkbox" id="windowsService" formControlName="windowsService">
|
<input type="checkbox" id="windowsService" formControlName="windowsService">
|
||||||
|
|
|
@ -35,6 +35,7 @@ export class UpdateComponent implements OnInit {
|
||||||
scriptLocation: [x.scriptLocation],
|
scriptLocation: [x.scriptLocation],
|
||||||
windowsService: [x.windowsService],
|
windowsService: [x.windowsService],
|
||||||
windowsServiceName: [x.windowsServiceName],
|
windowsServiceName: [x.windowsServiceName],
|
||||||
|
testMode: [x.testMode],
|
||||||
});
|
});
|
||||||
this.isWindows = x.isWindows;
|
this.isWindows = x.isWindows;
|
||||||
this.enableUpdateButton = x.autoUpdateEnabled;
|
this.enableUpdateButton = x.autoUpdateEnabled;
|
||||||
|
@ -62,7 +63,7 @@ export class UpdateComponent implements OnInit {
|
||||||
this.notificationService.error("Please check your entered values");
|
this.notificationService.error("Please check your entered values");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
this.enableUpdateButton = form.value.autoUpdateEnabled;
|
this.enableUpdateButton = form.value.autoUpdateEnabled || form.value.testMode;
|
||||||
this.settingsService.saveUpdateSettings(form.value)
|
this.settingsService.saveUpdateSettings(form.value)
|
||||||
.subscribe(x => {
|
.subscribe(x => {
|
||||||
if (x) {
|
if (x) {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue