mirror of
https://github.com/Squidly271/community.applications.git
synced 2025-06-03 14:52:13 +08:00
fix private stuff
This commit is contained in:
parent
2d8c2d588d
commit
c146b2c36d
BIN
archive/community.applications-2022.12.29-x86_64-1.txz
Normal file
BIN
archive/community.applications-2022.12.29-x86_64-1.txz
Normal file
Binary file not shown.
@ -2,8 +2,8 @@
|
|||||||
<!DOCTYPE PLUGIN [
|
<!DOCTYPE PLUGIN [
|
||||||
<!ENTITY name "community.applications">
|
<!ENTITY name "community.applications">
|
||||||
<!ENTITY author "Andrew Zawadzki">
|
<!ENTITY author "Andrew Zawadzki">
|
||||||
<!ENTITY version "2022.12.28">
|
<!ENTITY version "2022.12.29">
|
||||||
<!ENTITY md5 "2b6392f807d867b2f645e33caa9e2df5">
|
<!ENTITY md5 "7796f6fb9aed632b7803ff8b4aebcfd1">
|
||||||
<!ENTITY launch "Apps">
|
<!ENTITY launch "Apps">
|
||||||
<!ENTITY plugdir "/usr/local/emhttp/plugins/&name;">
|
<!ENTITY plugdir "/usr/local/emhttp/plugins/&name;">
|
||||||
<!ENTITY github "Squidly271/community.applications">
|
<!ENTITY github "Squidly271/community.applications">
|
||||||
@ -13,6 +13,10 @@
|
|||||||
<PLUGIN name="&name;" author="&author;" version="&version;" launch="&launch;" pluginURL="&pluginURL;" min="6.9.0" support="https://lime-technology.com/forums/topic/38582-plug-in-community-applications/" icon="users">
|
<PLUGIN name="&name;" author="&author;" version="&version;" launch="&launch;" pluginURL="&pluginURL;" min="6.9.0" support="https://lime-technology.com/forums/topic/38582-plug-in-community-applications/" icon="users">
|
||||||
|
|
||||||
<CHANGES>
|
<CHANGES>
|
||||||
|
###2022.12.29
|
||||||
|
- Fixed: Private App Category was not displaying
|
||||||
|
- Fixed: First load of Apps after a application feed download would result in system thinking no docker apps installed
|
||||||
|
|
||||||
###2022.12.28
|
###2022.12.28
|
||||||
- Fixed: PHP8 compliance
|
- Fixed: PHP8 compliance
|
||||||
- Changed: Debugging banner enabled now will auto-hide
|
- Changed: Debugging banner enabled now will auto-hide
|
||||||
|
@ -2,8 +2,8 @@ b02e9cd2ed57b27e0d29cef4a759b65f ./Apps.page
|
|||||||
4e55f7483b661af21a25b677179baffe ./CA_notices.page
|
4e55f7483b661af21a25b677179baffe ./CA_notices.page
|
||||||
600469ce287cb1ed78dc6cc11675cfaf ./ca_settings.page
|
600469ce287cb1ed78dc6cc11675cfaf ./ca_settings.page
|
||||||
e8d29607ec792ddf9f6832b10ee70fdc ./default.cfg
|
e8d29607ec792ddf9f6832b10ee70fdc ./default.cfg
|
||||||
e7d0e2bf7aeecb97126436a82f36bebf ./include/exec.php
|
565e74e0eb829851e13b19a8d7746400 ./include/exec.php
|
||||||
ed2434abe05335b87ddd9d2abc929ea8 ./include/helpers.php
|
c0992dbf9aa4f038c7ac2a1c492370f1 ./include/helpers.php
|
||||||
8d15446d4edf60a1f4ac4493a494a301 ./include/paths.php
|
8d15446d4edf60a1f4ac4493a494a301 ./include/paths.php
|
||||||
532fffdf939594c143e679da02bd841e ./javascript/libraries.js
|
532fffdf939594c143e679da02bd841e ./javascript/libraries.js
|
||||||
71f911a818d88d3d567f8a2898094ee2 ./README.md
|
71f911a818d88d3d567f8a2898094ee2 ./README.md
|
||||||
|
@ -212,7 +212,6 @@ function DownloadApplicationFeed() {
|
|||||||
$info = readJsonFile($caPaths['info']);
|
$info = readJsonFile($caPaths['info']);
|
||||||
exec("rm -rf '{$caPaths['tempFiles']}'");
|
exec("rm -rf '{$caPaths['tempFiles']}'");
|
||||||
@mkdir($caPaths['templates-community'],0777,true);
|
@mkdir($caPaths['templates-community'],0777,true);
|
||||||
writeJsonFile($caPaths['info'],$info);
|
|
||||||
|
|
||||||
$currentFeed = "Primary Server";
|
$currentFeed = "Primary Server";
|
||||||
$downloadURL = randomFile();
|
$downloadURL = randomFile();
|
||||||
@ -442,7 +441,6 @@ function updatePluginSupport($templates) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function getConvertedTemplates() {
|
function getConvertedTemplates() {
|
||||||
return;
|
|
||||||
global $caPaths, $caSettings, $statistics;
|
global $caPaths, $caSettings, $statistics;
|
||||||
|
|
||||||
# Start by removing any pre-existing private (converted templates)
|
# Start by removing any pre-existing private (converted templates)
|
||||||
@ -452,28 +450,25 @@ function getConvertedTemplates() {
|
|||||||
|
|
||||||
$myTemplates = [];
|
$myTemplates = [];
|
||||||
foreach ($templates as $template) {
|
foreach ($templates as $template) {
|
||||||
if ( ! ($template['Private'] ?? true) )
|
if ( ! $template['Private'] )
|
||||||
$myTemplates[] = $template;
|
$myTemplates[] = $template;
|
||||||
}
|
}
|
||||||
$appCount = count($myTemplates);
|
$appCount = count($myTemplates);
|
||||||
$i = $appCount;
|
$i = $appCount;
|
||||||
unset($Repos);
|
|
||||||
|
|
||||||
if ( ! is_dir($caPaths['convertedTemplates']) ) {
|
if ( ! is_dir($caPaths['convertedTemplates']) ) {
|
||||||
writeJsonFile($caPaths['community-templates-info'],$myTemplates);
|
writeJsonFile($caPaths['community-templates-info'],$myTemplates);
|
||||||
$GLOBALS['templates'] = $myTemplates;
|
$GLOBALS['templates'] = $myTemplates;
|
||||||
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
$privateTemplates = glob($caPaths['convertedTemplates']."*/*.xml");
|
$privateTemplates = glob($caPaths['convertedTemplates']."*/*.xml");
|
||||||
foreach ($privateTemplates as $template) {
|
foreach ($privateTemplates as $templateXML) {
|
||||||
$o = addMissingVars(readXmlFile($template));
|
$o = addMissingVars(readXmlFile($templateXML));
|
||||||
|
|
||||||
if ( ! $o['Repository'] ) continue;
|
if ( ! $o['Repository'] ) continue;
|
||||||
|
|
||||||
$o['Private'] = true;
|
$o['Private'] = true;
|
||||||
$o['RepoName'] = basename(pathinfo($template,PATHINFO_DIRNAME))." Repository";
|
$o['RepoName'] = basename(pathinfo($templateXML,PATHINFO_DIRNAME))." Repository";
|
||||||
$o['ID'] = $i;
|
$o['ID'] = $i;
|
||||||
$o['Displayable'] = true;
|
$o['Displayable'] = true;
|
||||||
$o['Date'] = ( $o['Date'] ) ? strtotime( $o['Date'] ) : 0;
|
$o['Date'] = ( $o['Date'] ) ? strtotime( $o['Date'] ) : 0;
|
||||||
@ -487,7 +482,6 @@ function getConvertedTemplates() {
|
|||||||
}
|
}
|
||||||
writeJsonFile($caPaths['community-templates-info'],$myTemplates);
|
writeJsonFile($caPaths['community-templates-info'],$myTemplates);
|
||||||
$GLOBALS['templates'] = $myTemplates;
|
$GLOBALS['templates'] = $myTemplates;
|
||||||
return true;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#############################
|
#############################
|
||||||
|
@ -652,8 +652,9 @@ function write_ini_file($file,$array) {
|
|||||||
function getAllInfo($force=false) {
|
function getAllInfo($force=false) {
|
||||||
global $caSettings, $DockerTemplates, $DockerClient, $caPaths;
|
global $caSettings, $DockerTemplates, $DockerClient, $caPaths;
|
||||||
|
|
||||||
$containers = [];
|
$containers = readJsonFile($caPaths['info']);
|
||||||
if ( $force ) {
|
|
||||||
|
if ( $force || ! $containers || empty($containers) ) {
|
||||||
if ( $caSettings['dockerRunning'] ?? false ) {
|
if ( $caSettings['dockerRunning'] ?? false ) {
|
||||||
$info = $DockerTemplates->getAllInfo(false,true,true);
|
$info = $DockerTemplates->getAllInfo(false,true,true);
|
||||||
$containers = $DockerClient->getDockerContainers();
|
$containers = $DockerClient->getDockerContainers();
|
||||||
@ -666,7 +667,6 @@ function getAllInfo($force=false) {
|
|||||||
debug("Forced info update");
|
debug("Forced info update");
|
||||||
writeJsonFile($caPaths['info'],$containers);
|
writeJsonFile($caPaths['info'],$containers);
|
||||||
} else {
|
} else {
|
||||||
$containers = readJsonFile($caPaths['info']);
|
|
||||||
debug("Cached info update");
|
debug("Cached info update");
|
||||||
}
|
}
|
||||||
return $containers;
|
return $containers;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user