Forum Programmation.shell [Résolu] Appel de SSH depuis un Shell script (Bash)

Posté par  (site web personnel) . Licence CC By‑SA.
Étiquettes :
1
13
juin
2014

Bonjour,

En voulant appeler SSH depuis un script Shell (Bash), j'ai les erreurs suivantes : Pseudo-terminal will not be allocated because stdin is not a terminal. et stdin: is not a tty

Ma ligne de commande pour appeler le SSH est la suivante :
DISPLAY=y SSH_ASKPASS=filename setsid ssh -t -X -o 'PreferredAuthentications password,keyboard-interactive' -o 'StrictHostKeyChecking no' ${1:-}

En googlant un peu, j'ai essayé la méthode indiquant d'ajouter un -t et donc avec la ligne de commande suivante, j'ai une autre (…)