Bug 1326 - [BackupPC] le script d'installation pour OSX n'active pas SSHD : correction du bug en ajoutant une commande qui active le service ssh. J'ai testé le scrip et il fonctionne sur simpa-macbook2 (osx 10.10).
This commit is contained in:
parent
19f0b3e20d
commit
739c2f6dd9
|
@ -44,7 +44,13 @@ function ensureSshdIsRunning()
|
|||
sudo launchctl list | grep 'com.openssh.sshd' &> /dev/null
|
||||
if [ $? != 0 ]; then
|
||||
# enable 'Remote login' in 'system preferences'
|
||||
launchctl load /System/Library/LaunchDaemons/ssh.plist &> /dev/null
|
||||
sudo launchctl enable system/com.openssh.sshd &> /dev/null
|
||||
|
||||
sudo launchctl load /System/Library/LaunchDaemons/ssh.plist &> /dev/null
|
||||
fi
|
||||
sudo launchctl list | grep 'com.openssh.sshd' &> /dev/null
|
||||
if [ $? != 0 ]; then
|
||||
printf '\e[1;31m%-6s\e[m' "L'activation du serveur ssh a échoué"; return "$ERROR"
|
||||
fi
|
||||
;;
|
||||
'Linux')
|
||||
|
@ -232,6 +238,9 @@ fi
|
|||
|
||||
#### INSTALLATION DE OPENSSH-SERVER ####
|
||||
ensureSshdIsRunning
|
||||
if [ "$?" != "$SUCCESS" ]; then
|
||||
printf '\e[1;31m%-6s\e[m' "L'installation du serveur ssh a échoué, installation annulée."; exit
|
||||
fi
|
||||
hostkey=$(getMyHostKey)
|
||||
#printf "hostkey=$hostkey"
|
||||
if [ "$?" != "$SUCCESS" ]; then
|
||||
|
|
Loading…
Reference in New Issue