Page MenuHomePhabricator

D15726.diff
No OneTemporary

D15726.diff

diff --git a/src/applications/daemon/management/PhabricatorDaemonManagementWorkflow.php b/src/applications/daemon/management/PhabricatorDaemonManagementWorkflow.php
--- a/src/applications/daemon/management/PhabricatorDaemonManagementWorkflow.php
+++ b/src/applications/daemon/management/PhabricatorDaemonManagementWorkflow.php
@@ -224,17 +224,18 @@
$daemon_script_dir,
$config,
$this->runDaemonsAsUser);
- } catch (Exception $e) {
- // Retry without sudo
- $console->writeOut(
- "%s\n",
+ } catch (Exception $ex) {
+ throw new PhutilArgumentUsageException(
pht(
- '%s command failed. Starting daemon as current user.',
- 'sudo'));
- $this->executeDaemonLaunchCommand(
- $command,
- $daemon_script_dir,
- $config);
+ 'Daemons are configured to run as user "%s" in configuration '.
+ 'option `%s`, but the current user is "%s" and `phd` was unable '.
+ 'to switch to the correct user with `sudo`. Command output:'.
+ "\n\n".
+ '%s',
+ $phd_user,
+ 'phd.user',
+ $current_user,
+ $ex->getMessage()));
}
}
}

File Metadata

Mime Type
text/plain
Expires
Sat, Dec 21, 11:56 AM (18 h, 12 s)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
6913897
Default Alt Text
D15726.diff (1 KB)

Event Timeline