Bonjour,
est-il possible d’intégrer une evolution permettant le choix du port SSH. J’ai modifié le code pour prendre en compte mes « contraintes » mais ce n’est pas terrible
if ($this->getEqLogic()->getConfiguration('cli::mode') == 'ssh') {
$_cmd = str_replace(system::getCmdSudo(), '', $_cmd);
$connection = ssh2_connect($this->getEqLogic()->getConfiguration('ssh::ip'), $this->getEqLogic()->getConfiguration('ssh::port', 22));
if ($connection === false) {
$connection = ssh2_connect($this->getEqLogic()->getConfiguration('ssh::ip'), $this->getEqLogic()->getConfiguration('ssh::port', 50022));
if ($connection === false) {
throw new Exception(__('Impossible de se connecter sur :', __FILE__) . ' ' . $this->getEqLogic()->getConfiguration('ssh::ip') . ':' . $this->getEqLogic()->getConfiguration('ssh::port', 22));
}
}