//guess what this does
OC_Installer::installShippedApps();
- //create htaccess files for apache hosts
+ // create empty file in data dir, so we can later find
+ // out that this is indeed an ownCloud data directory
+ file_put_contents(OC_Config::getValue('datadirectory', OC::$SERVERROOT.'/data').'/.ocdata', '');
+
+ // Update htaccess files for apache hosts
if (isset($_SERVER['SERVER_SOFTWARE']) && strstr($_SERVER['SERVER_SOFTWARE'], 'Apache')) {
- self::createHtaccess();
+ self::updateHtaccess();
+ self::protectDataDirectory();
}
//and we are done
}
$this->emit('\OC\Updater', 'maintenanceStart');
+ // Update htaccess files for apache hosts
+ if (isset($_SERVER['SERVER_SOFTWARE']) && strstr($_SERVER['SERVER_SOFTWARE'], 'Apache')) {
+ \OC_Setup::updateHtaccess();
+ }
+
+ // create empty file in data dir, so we can later find
+ // out that this is indeed an ownCloud data directory
+ // (in case it didn't exist before)
+ file_put_contents(\OC_Config::getValue('datadirectory', \OC::$SERVERROOT.'/data').'/.ocdata', '');
+
/*
* START CONFIG CHANGES FOR OLDER VERSIONS
*/