mirror of
https://github.com/nextcloud/server.git
synced 2026-03-04 18:28:08 +01:00
Show a warning in the installer if .htaccess is not working
This commit is contained in:
@@ -6,6 +6,12 @@ $hasPostgreSQL = is_callable('pg_connect');
|
||||
$hasOracle = is_callable('oci_connect');
|
||||
$datadir = OC_Config::getValue('datadirectory', OC::$SERVERROOT.'/data');
|
||||
|
||||
// Test if .htaccess is working
|
||||
$content = "<Directory /data>\n";
|
||||
$content.= "Deny from All\n";
|
||||
$content.= "</Directory>";
|
||||
file_put_contents(OC::$SERVERROOT.'/data/.htaccess', $content);
|
||||
|
||||
$opts = array(
|
||||
'hasSQLite' => $hasSQLite,
|
||||
'hasMySQL' => $hasMySQL,
|
||||
@@ -13,6 +19,7 @@ $opts = array(
|
||||
'hasOracle' => $hasOracle,
|
||||
'directory' => $datadir,
|
||||
'secureRNG' => OC_Util::secureRNG_available(),
|
||||
'htaccessWorking' => OC_Util::ishtaccessworking(),
|
||||
'errors' => array(),
|
||||
);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user