All the content of the archive doesn't unzip when I use the php function ssh2_exec()
There is around 10 files and 5 folders in my ziparchive and the system unzip sometimes just 3 files another time the system unzip 1 folder and 3 files....
My code :
$host_ssh = 'ssh.something';
$identifiant = 'username';
$mdp = 'xyzyoupi';
$connection = ssh2_connect($host_ssh , 22);
ssh2_auth_password($connection,$identifiant,$mdp);
if(ssh2_exec($connection, 'unzip -o dirRoot/filename.zip')){
echo 'unzip ok<br>';
}else{
echo 'unzip not ok<br>';
}
I'm using php7.2