Changeset View
Changeset View
Standalone View
Standalone View
src/applications/harbormaster/step/CommandBuildStepImplementation.php
Show First 20 Lines • Show All 84 Lines • ▼ Show 20 Lines | if ($settings['hostartifact'] === null || | ||||
return false; | return false; | ||||
} | } | ||||
// TODO: Check if the host artifact is provided by previous build steps. | // TODO: Check if the host artifact is provided by previous build steps. | ||||
return true; | return true; | ||||
} | } | ||||
public function getArtifactInputs() { | |||||
return array( | |||||
array( | |||||
'name' => pht('Run on Host'), | |||||
'key' => $this->getSetting('hostartifact'), | |||||
'type' => HarbormasterBuildArtifact::TYPE_HOST, | |||||
), | |||||
); | |||||
} | |||||
public function getSettingDefinitions() { | public function getSettingDefinitions() { | ||||
return array( | return array( | ||||
'command' => array( | 'command' => array( | ||||
'name' => 'Command', | 'name' => 'Command', | ||||
'description' => 'The command to execute on the remote machine.', | 'description' => 'The command to execute on the remote machine.', | ||||
'type' => BuildStepImplementation::SETTING_TYPE_STRING), | 'type' => BuildStepImplementation::SETTING_TYPE_STRING), | ||||
'hostartifact' => array( | 'hostartifact' => array( | ||||
'name' => 'Host Artifact', | 'name' => 'Host Artifact', | ||||
'description' => | 'description' => | ||||
'The host artifact that determines what machine the command '. | 'The host artifact that determines what machine the command '. | ||||
'will run on.', | 'will run on.', | ||||
'type' => BuildStepImplementation::SETTING_TYPE_ARTIFACT, | 'type' => BuildStepImplementation::SETTING_TYPE_ARTIFACT, | ||||
'artifact_type' => HarbormasterBuildArtifact::TYPE_HOST)); | 'artifact_type' => HarbormasterBuildArtifact::TYPE_HOST)); | ||||
} | } | ||||
} | } |