Skip to content

Commit 467c8a9

Browse files
committed
Remove the CAN_INSTALL file when occ maintenance:install is complete
When occ maintenance:install is run from the CLI, the CAN_INSTALL in the config directory is left in place when installed is set to true, whereas this file is removed when the web installer is used. Removing this file in the CLI command maintains consistency between the two. This allows automation tools an easier way to determine if this process has been completed. Signed-off-by: Alex Harpin <development@landsofshadow.co.uk>
1 parent 10cca65 commit 467c8a9

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

lib/private/Setup.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -419,6 +419,9 @@ public function install($options) {
419419

420420
//and we are done
421421
$config->setSystemValue('installed', true);
422+
if (\OC_Util::getChannel() !== 'git' && is_file(\OC::$configDir.'/CAN_INSTALL')) {
423+
unlink(\OC::$configDir.'/CAN_INSTALL');
424+
}
422425

423426
$bootstrapCoordinator = \OC::$server->query(\OC\AppFramework\Bootstrap\Coordinator::class);
424427
$bootstrapCoordinator->runInitialRegistration();

0 commit comments

Comments
 (0)