Skip to content

Commit 834079f

Browse files
author
epriestley
committedJan 28, 2015
Pass cluster.instance to ssh-exec if it is defined
Summary: Ref T7034. This is a second special case, like commit hooks, where we need some help from Phabricator to make instance identity knowable. Test Plan: Connected to an instance and ran SSH commands. Reviewers: btrahan Reviewed By: btrahan Subscribers: epriestley Maniphest Tasks: T7034 Differential Revision: https://secure.phabricator.com/D11539
1 parent 170dc15 commit 834079f

File tree

2 files changed

+16
-6
lines changed

2 files changed

+16
-6
lines changed
 

‎resources/celerity/map.php

+5-5
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*/
88
return array(
99
'names' => array(
10-
'core.pkg.css' => '8815f87d',
10+
'core.pkg.css' => '04a24e98',
1111
'core.pkg.js' => 'efa12ecc',
1212
'darkconsole.pkg.js' => '8ab24e01',
1313
'differential.pkg.css' => '8af45893',
@@ -125,7 +125,7 @@
125125
'rsrc/css/phui/phui-action-list.css' => '9ee9910a',
126126
'rsrc/css/phui/phui-box.css' => '7b3a2eed',
127127
'rsrc/css/phui/phui-button.css' => '008ba5e2',
128-
'rsrc/css/phui/phui-crumbs-view.css' => '646a8830',
128+
'rsrc/css/phui/phui-crumbs-view.css' => '3e362700',
129129
'rsrc/css/phui/phui-document.css' => 'bbeb1890',
130130
'rsrc/css/phui/phui-feed-story.css' => 'c9f3a0b5',
131131
'rsrc/css/phui/phui-fontkit.css' => '9c3d2dce',
@@ -137,7 +137,7 @@
137137
'rsrc/css/phui/phui-info-panel.css' => '27ea50a1',
138138
'rsrc/css/phui/phui-list.css' => '53deb25c',
139139
'rsrc/css/phui/phui-object-box.css' => '0d47b3c8',
140-
'rsrc/css/phui/phui-object-item-list-view.css' => '2686a80e',
140+
'rsrc/css/phui/phui-object-item-list-view.css' => '832c58fe',
141141
'rsrc/css/phui/phui-pinboard-view.css' => '3dd4a269',
142142
'rsrc/css/phui/phui-property-list-view.css' => '51480060',
143143
'rsrc/css/phui/phui-remarkup-preview.css' => '19ad512b',
@@ -770,7 +770,7 @@
770770
'phui-calendar-day-css' => 'de035c8a',
771771
'phui-calendar-list-css' => 'c1d0ca59',
772772
'phui-calendar-month-css' => 'a92e47d2',
773-
'phui-crumbs-view-css' => '646a8830',
773+
'phui-crumbs-view-css' => '3e362700',
774774
'phui-document-view-css' => 'bbeb1890',
775775
'phui-feed-story-css' => 'c9f3a0b5',
776776
'phui-font-icon-base-css' => '3dad2ae3',
@@ -783,7 +783,7 @@
783783
'phui-info-panel-css' => '27ea50a1',
784784
'phui-list-view-css' => '53deb25c',
785785
'phui-object-box-css' => '0d47b3c8',
786-
'phui-object-item-list-view-css' => '2686a80e',
786+
'phui-object-item-list-view-css' => '832c58fe',
787787
'phui-pinboard-view-css' => '3dd4a269',
788788
'phui-property-list-view-css' => '51480060',
789789
'phui-remarkup-preview-css' => '19ad512b',

‎scripts/ssh/ssh-auth.php

+11-1
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,17 @@
2626
foreach ($keys as $ssh_key) {
2727
$user = $ssh_key->getObject()->getUsername();
2828

29-
$cmd = csprintf('%s --phabricator-ssh-user %s', $bin, $user);
29+
$key_argv = array();
30+
$key_argv[] = '--phabricator-ssh-user';
31+
$key_argv[] = $user;
32+
33+
$cmd = csprintf('%s %Ls', $bin, $key_argv);
34+
35+
$instance = PhabricatorEnv::getEnvConfig('cluster.instance');
36+
if (strlen($instance)) {
37+
$cmd = csprintf('PHABRICATOR_INSTANCE=%s %C', $instance, $cmd);
38+
}
39+
3040
// This is additional escaping for the SSH 'command="..."' string.
3141
$cmd = addcslashes($cmd, '"\\');
3242

0 commit comments

Comments
 (0)
Failed to load comments.