|
@@ -77,7 +77,7 @@ class Release extends Command
|
|
|
private $_user_system;
|
|
|
|
|
|
/**
|
|
|
- * @var string $directory Directorio de instalación
|
|
|
+ * @var string $directory Directorio de instalación
|
|
|
*/
|
|
|
private $directory;
|
|
|
|
|
@@ -243,12 +243,28 @@ class Release extends Command
|
|
|
->addOption('client', null, InputOption::VALUE_REQUIRED, 'Client name, if is not provided uses, the dirname of the installation', false)
|
|
|
->addOption('modules', null, InputOption::VALUE_REQUIRED, 'List of modules to install separated by coma.', "all")
|
|
|
->addOption('inventory', null, InputOption::VALUE_REQUIRED, 'Write inventory.ini by default.', true)
|
|
|
- ->addOption('docker-tag', null, InputOption::VALUE_REQUIRED, 'Docker tag to be used', "latest");
|
|
|
+ ->addOption('docker-tag', null, InputOption::VALUE_REQUIRED, 'Docker tag to be used', "latest")
|
|
|
+ ->addOption('all-ref', null, InputOption::VALUE_REQUIRED, 'Git reference (branch or tag) to clone all app', "")
|
|
|
+ ->addOption('general-version', null, InputOption::VALUE_REQUIRED, 'Set options all-ref and docker-tag with this value. Ej. 0.1.1', "");
|
|
|
}
|
|
|
|
|
|
protected function execute(InputInterface $input, OutputInterface $output)
|
|
|
{
|
|
|
try {
|
|
|
+ if (strlen(trim($input->getOption("general-version"))) > 0) {
|
|
|
+ $input->setOption('all-ref', 'v' . $input->getOption('general-version'));
|
|
|
+ $input->setOption('docker-tag', $input->getOption('general-version'));
|
|
|
+ }
|
|
|
+ if (strlen(trim($input->getOption("all-ref"))) > 0) {
|
|
|
+ $input->setOption('base-ref', $input->getOption('all-ref'));
|
|
|
+ $input->setOption('ftth-ref', $input->getOption('all-ref'));
|
|
|
+ $input->setOption('mapas-ref', $input->getOption('all-ref'));
|
|
|
+ $input->setOption('radius-ref', $input->getOption('all-ref'));
|
|
|
+ $input->setOption('stats-ref', $input->getOption('all-ref'));
|
|
|
+ $input->setOption('cablemodem-ref', $input->getOption('all-ref'));
|
|
|
+ $input->setOption('dhcp-ref', $input->getOption('all-ref'));
|
|
|
+ $input->setOption('extra-ref', $input->getOption('all-ref'));
|
|
|
+ }
|
|
|
if (strtolower($input->getOption("modules")) == "all") {
|
|
|
// seteo todos los modulos a instalar por defecto
|
|
|
$modules = "";
|