fix(cicd): Disable SSH host key verification for LINSTOR connections
Some checks failed
CD - Deploy Infrastructure / Terraform Validation (push) Successful in 17s
CD - Deploy Infrastructure / Deploy on pve1 (push) Failing after 9s
CD - Deploy Infrastructure / Deploy on pve2 (push) Failing after 8s
CD - Deploy Infrastructure / Deploy on pve3 (push) Successful in 1m53s
CD - Deploy Infrastructure / Validate K3s Cluster (push) Has been skipped
CD - Deploy Infrastructure / Deployment Notification (push) Failing after 1s
Some checks failed
CD - Deploy Infrastructure / Terraform Validation (push) Successful in 17s
CD - Deploy Infrastructure / Deploy on pve1 (push) Failing after 9s
CD - Deploy Infrastructure / Deploy on pve2 (push) Failing after 8s
CD - Deploy Infrastructure / Deploy on pve3 (push) Successful in 1m53s
CD - Deploy Infrastructure / Validate K3s Cluster (push) Has been skipped
CD - Deploy Infrastructure / Deployment Notification (push) Failing after 1s
- Ajoute -o StrictHostKeyChecking=no et -o UserKnownHostsFile=/dev/null - Résout l'erreur 'Host key verification failed' - Nécessaire car le container Docker n'a pas les clés d'hôtes enregistrées
This commit is contained in:
parent
6628870938
commit
ddc9b1a98b
1 changed files with 7 additions and 2 deletions
|
|
@ -67,8 +67,13 @@ class LinstorManager:
|
|||
remote_host: Si spécifié, exécute la commande via SSH sur cet hôte
|
||||
"""
|
||||
if remote_host:
|
||||
# Construit la commande SSH
|
||||
ssh_command = ['ssh', f'root@{remote_host}'] + command
|
||||
# Construit la commande SSH avec options pour désactiver la vérification de clé d'hôte
|
||||
ssh_command = [
|
||||
'ssh',
|
||||
'-o', 'StrictHostKeyChecking=no',
|
||||
'-o', 'UserKnownHostsFile=/dev/null',
|
||||
f'root@{remote_host}'
|
||||
] + command
|
||||
self.log(f"Exécution SSH sur {remote_host}: {' '.join(command)}")
|
||||
command = ssh_command
|
||||
else:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue