Skip to content
Snippets Groups Projects
Commit b2d9400c authored by Hahn Axel (hahn)'s avatar Hahn Axel (hahn)
Browse files

fix rollout plugins

parent 0f8622f8
No related branches found
No related tags found
1 merge request!62V2.0
......@@ -451,9 +451,9 @@ class rollout_base implements iRolloutplugin{
// ----------------------------------------------------------------------
/**
* get a hash with the merged config for project or mo specific: of a given
* phase
* @param string $sPhase
* get configuration for the project .. or more specifi for a given phase
* @param string $sPhase
* @param boolean $bMask Flag for public output; if true then mask your secrets
* @return array
*/
public function getConfig($sPhase=false, $bMask=false){
......@@ -476,10 +476,11 @@ class rollout_base implements iRolloutplugin{
/**
* get an array with shell commands to execute
* @param string $sPhase
* @param string $sPhase
* @param boolean $bMask Flag for public output; if true then mask your secrets
* @return array
*/
public function getDeployCommands($sPhase){
public function getDeployCommands($sPhase, $bMask=false){
return [
'echo "ERROR: The method getDeployCommamds($sPhase) was not implemented in the rollout plugin ['.$this->getId().']"',
'exit 1'
......
......@@ -167,12 +167,13 @@ class rollout_awx extends rollout_base {
/**
* get array with commands to execute to deploy a package
*
* @param string $sPhase phase
* @param string $sPhase
* @param boolean $bMask Flag for public output; if true then mask your secrets
* @return array
*/
public function getDeployCommands($sPhase){
public function getDeployCommands($sPhase, $bMask=false){
$aReturn=array();
$aConfig=$this->getConfig($sPhase);
$aConfig=$this->getConfig($sPhase, $bMask);
// ----- Checks:
$sCmdChecks='';
......@@ -185,7 +186,7 @@ class rollout_awx extends rollout_base {
}
if(!isset($aConfig['inventory']) || !(int)$aConfig['inventory']){
$sCmdChecks.='echo "ERROR: no inventory was given."; exit 1; ';
$sCmdChecks.='echo "ERROR: no awx inventory was given."; exit 1; ';
}
// ----- Send variables having values only
......
......@@ -28,10 +28,11 @@ class rollout_default extends rollout_base {
/**
* get array with commands to execute to deploy a package
*
* @param string $sPhase phase
* @param string $sPhase
* @param boolean $bMask Flag for public output; if true then mask your secrets
* @return array
*/
public function getDeployCommands($sPhase){
public function getDeployCommands($sPhase, $bMask=false){
return [
'echo "SKIP"'
];
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment