diff --git a/OBI.php b/OBI.php index f0a51e5..c4182a4 100644 --- a/OBI.php +++ b/OBI.php @@ -76,12 +76,13 @@ if (isset($_POST['save']) && $_POST['save']) { if (empty($input_errors)) { $config['onebuttoninstaller']['storage_path'] = !empty($_POST['storage_path']) ? $_POST['storage_path'] : $g['media_path']; $config['onebuttoninstaller']['storage_path'] = rtrim($config['onebuttoninstaller']['storage_path'],'/'); // ensure to have NO trailing slash - if (strpos($config['onebuttoninstaller']['storage_path'], "/mnt/") === false) { + if (!isset($_POST['path_check']) && (strpos($config['onebuttoninstaller']['storage_path'], "/mnt/") === false)) { $input_errors[] = gettext("The common directory for all extensions MUST be set to a directory below '/mnt/' to prevent to loose the extensions after a reboot on embedded systems!"); } else { if (!is_dir($config['onebuttoninstaller']['storage_path'])) mkdir($config['onebuttoninstaller']['storage_path'], 0775, true); change_perms($config['onebuttoninstaller']['storage_path']); + $config['onebuttoninstaller']['path_check'] = isset($_POST['path_check']) ? true : false; $install_dir = $config['onebuttoninstaller']['storage_path']."/"; // get directory where the installer script resides if (!is_dir("{$install_dir}onebuttoninstaller/log")) { mkdir("{$install_dir}onebuttoninstaller/log", 0775, true); } $return_val = mwexec("fetch {$verify_hostname} -vo {$install_dir}onebuttoninstaller/onebuttoninstaller-install.php 'https://raw.github.com/crestAT/nas4free-onebuttoninstaller/master/onebuttoninstaller/onebuttoninstaller-install.php'", true); @@ -91,7 +92,7 @@ if (isset($_POST['save']) && $_POST['save']) { } else { $input_errors[] = sprintf(gettext("Installation file %s not found, installation aborted!"), "{$install_dir}onebuttoninstaller/onebuttoninstaller-install.php"); - exit; + return; } mwexec("rm -Rf ext/OBI; rm -f OBI.php", true); header("Location:onebuttoninstaller-config.php"); @@ -107,6 +108,7 @@ if (isset($_POST['cancel']) && $_POST['cancel']) { } $pconfig['storage_path'] = !empty($config['onebuttoninstaller']['storage_path']) ? $config['onebuttoninstaller']['storage_path'] : $g['media_path']; +$pconfig['path_check'] = isset($config['onebuttoninstaller']['path_check']) ? true : false; include("fbegin.inc"); ?>
@@ -117,7 +119,7 @@ include("fbegin.inc"); ?> /mnt/)."), $pconfig['storage_path'], true, 60);?> -
+ ".gettext("Please use this option only if you know what you are doing!")."", false);?>
"/> "/> diff --git a/onebuttoninstaller/ext/onebuttoninstaller-config.php b/onebuttoninstaller/ext/onebuttoninstaller-config.php index b9f3ddd..625fdeb 100644 --- a/onebuttoninstaller/ext/onebuttoninstaller-config.php +++ b/onebuttoninstaller/ext/onebuttoninstaller-config.php @@ -148,7 +148,7 @@ function enable_change(enable_change) { /mnt/)."), $pconfig['storage_path'], true, 60);?> - + ".gettext("Please use this option only if you know what you are doing!")."", false);?> diff --git a/onebuttoninstaller/locale-obi/de/LC_MESSAGES/nas4free.mo b/onebuttoninstaller/locale-obi/de/LC_MESSAGES/nas4free.mo index b62fda1..67b0889 100644 Binary files a/onebuttoninstaller/locale-obi/de/LC_MESSAGES/nas4free.mo and b/onebuttoninstaller/locale-obi/de/LC_MESSAGES/nas4free.mo differ diff --git a/onebuttoninstaller/locale-obi/el/LC_MESSAGES/nas4free.mo b/onebuttoninstaller/locale-obi/el/LC_MESSAGES/nas4free.mo index b554b3f..ac3044b 100644 Binary files a/onebuttoninstaller/locale-obi/el/LC_MESSAGES/nas4free.mo and b/onebuttoninstaller/locale-obi/el/LC_MESSAGES/nas4free.mo differ diff --git a/onebuttoninstaller/locale-obi/es/LC_MESSAGES/nas4free.mo b/onebuttoninstaller/locale-obi/es/LC_MESSAGES/nas4free.mo index 3520031..5bed396 100644 Binary files a/onebuttoninstaller/locale-obi/es/LC_MESSAGES/nas4free.mo and b/onebuttoninstaller/locale-obi/es/LC_MESSAGES/nas4free.mo differ diff --git a/onebuttoninstaller/locale-obi/fr/LC_MESSAGES/nas4free.mo b/onebuttoninstaller/locale-obi/fr/LC_MESSAGES/nas4free.mo index b90e8d9..eb23f83 100644 Binary files a/onebuttoninstaller/locale-obi/fr/LC_MESSAGES/nas4free.mo and b/onebuttoninstaller/locale-obi/fr/LC_MESSAGES/nas4free.mo differ diff --git a/onebuttoninstaller/locale-obi/it/LC_MESSAGES/nas4free.mo b/onebuttoninstaller/locale-obi/it/LC_MESSAGES/nas4free.mo index 0b5b328..e0e093f 100644 Binary files a/onebuttoninstaller/locale-obi/it/LC_MESSAGES/nas4free.mo and b/onebuttoninstaller/locale-obi/it/LC_MESSAGES/nas4free.mo differ diff --git a/onebuttoninstaller/locale-obi/nl/LC_MESSAGES/nas4free.mo b/onebuttoninstaller/locale-obi/nl/LC_MESSAGES/nas4free.mo index a391b6f..6c9d8d9 100644 Binary files a/onebuttoninstaller/locale-obi/nl/LC_MESSAGES/nas4free.mo and b/onebuttoninstaller/locale-obi/nl/LC_MESSAGES/nas4free.mo differ diff --git a/onebuttoninstaller/locale-obi/ro/LC_MESSAGES/nas4free.mo b/onebuttoninstaller/locale-obi/ro/LC_MESSAGES/nas4free.mo index 4fd422e..ff90122 100644 Binary files a/onebuttoninstaller/locale-obi/ro/LC_MESSAGES/nas4free.mo and b/onebuttoninstaller/locale-obi/ro/LC_MESSAGES/nas4free.mo differ diff --git a/onebuttoninstaller/locale-obi/ru/LC_MESSAGES/nas4free.mo b/onebuttoninstaller/locale-obi/ru/LC_MESSAGES/nas4free.mo index d71fd96..d80257c 100644 Binary files a/onebuttoninstaller/locale-obi/ru/LC_MESSAGES/nas4free.mo and b/onebuttoninstaller/locale-obi/ru/LC_MESSAGES/nas4free.mo differ diff --git a/onebuttoninstaller/onebuttoninstaller-install.php b/onebuttoninstaller/onebuttoninstaller-install.php index 18fbf85..a9ec909 100644 --- a/onebuttoninstaller/onebuttoninstaller-install.php +++ b/onebuttoninstaller/onebuttoninstaller-install.php @@ -29,7 +29,7 @@ of the authors and should not be interpreted as representing official policies, either expressed or implied, of the FreeBSD Project. */ -$v = "v0.3"; // extension version +$v = "v0.3.1"; // extension version $appname = "OneButtonInstaller"; require_once("config.inc"); diff --git a/onebuttoninstaller/onebuttoninstaller-stop.php b/onebuttoninstaller/onebuttoninstaller-stop.php index c7fe2f2..e0249cd 100644 --- a/onebuttoninstaller/onebuttoninstaller-stop.php +++ b/onebuttoninstaller/onebuttoninstaller-stop.php @@ -32,5 +32,5 @@ $extension_dir = "/usr/local/www"; mwexec("rm -Rf {$extension_dir}/onebuttoninstaller*", true); mwexec("rm -Rf {$extension_dir}/ext/onebuttoninstaller", true); -exec("logger onebuttoninstaller: stopped"); +exec("logger onebuttoninstaller: stopped"); ?> diff --git a/onebuttoninstaller/onebuttoninstaller_start.php b/onebuttoninstaller/onebuttoninstaller_start.php index f437d93..9729bcc 100644 --- a/onebuttoninstaller/onebuttoninstaller_start.php +++ b/onebuttoninstaller/onebuttoninstaller_start.php @@ -1,5 +1,5 @@ #!/usr/local/bin/php-cgi -f diff --git a/onebuttoninstaller/onebuttoninstaller_stop.php b/onebuttoninstaller/onebuttoninstaller_stop.php index de4509a..819378e 100644 --- a/onebuttoninstaller/onebuttoninstaller_stop.php +++ b/onebuttoninstaller/onebuttoninstaller_stop.php @@ -1,5 +1,5 @@ #!/usr/local/bin/php-cgi -f diff --git a/onebuttoninstaller/release_notes.txt b/onebuttoninstaller/release_notes.txt index b3688d7..8bdef1b 100644 --- a/onebuttoninstaller/release_notes.txt +++ b/onebuttoninstaller/release_notes.txt @@ -1,4 +1,5 @@ Version Date Description +0.3.1 2016.08.15 F: OBI installer - add checkbox to override restriction for extensions installation path 0.3 2016.08.14 N: configuration - checkbox to override restriction for extensions installation path (limited to a directory under /mnt/) 0.2 2016.08.09 N: configuration - enable/disable beta releases in extensions list diff --git a/onebuttoninstaller/version.txt b/onebuttoninstaller/version.txt index be58634..9e11b32 100644 --- a/onebuttoninstaller/version.txt +++ b/onebuttoninstaller/version.txt @@ -1 +1 @@ -0.3 +0.3.1