3 final class PhabricatorAuthManagementLockWorkflow
4 extends PhabricatorAuthManagementWorkflow
{
6 protected function didConstruct() {
9 ->setExamples('**lock**')
12 'Lock authentication provider config, to prevent changes to '.
13 'the config without doing **bin/auth unlock**.'));
16 public function execute(PhutilArgumentParser
$args) {
17 $console = PhutilConsole
::getConsole();
19 $key = 'auth.lock-config';
20 $config_entry = PhabricatorConfigEntry
::loadConfigEntry($key);
21 $config_entry->setValue(true);
23 // If the entry has been deleted, resurrect it.
24 $config_entry->setIsDeleted(0);
26 $config_entry->save();
30 pht('Locked the authentication provider configuration.'));