diff --git a/src/Deployer/DefaultDeployer.php b/src/Deployer/DefaultDeployer.php index fa28adc..5ae1bb9 100644 --- a/src/Deployer/DefaultDeployer.php +++ b/src/Deployer/DefaultDeployer.php @@ -337,11 +337,24 @@ private function doInstallDependencies(): void { if (true === $this->getConfig(Option::updateRemoteComposerBinary)) { $this->log('

Self Updating the Composer binary'); - $this->runRemote(sprintf('%s self-update', $this->getConfig(Option::remoteComposerBinaryPath))); + $this->runRemote( + sprintf( + '%s %s self-update', + $this->getConfig(Option::remotePhpBinaryPath), + $this->getConfig(Option::remoteComposerBinaryPath) + ) + ); } $this->log('

Installing Composer dependencies'); - $this->runRemote(sprintf('%s install %s', $this->getConfig(Option::remoteComposerBinaryPath), $this->getConfig(Option::composerInstallFlags))); + $this->runRemote( + sprintf( + '%s %s install %s', + $this->getConfig(Option::remotePhpBinaryPath), + $this->getConfig(Option::remoteComposerBinaryPath), + $this->getConfig(Option::composerInstallFlags) + ) + ); } private function doInstallWebAssets(): void @@ -390,7 +403,14 @@ private function doClearControllers(): void private function doOptimizeComposer(): void { $this->log('

Optimizing Composer autoloader'); - $this->runRemote(sprintf('%s dump-autoload %s', $this->getConfig(Option::remoteComposerBinaryPath), $this->getConfig(Option::composerOptimizeFlags))); + $this->runRemote( + sprintf( + '%s %s dump-autoload %s', + $this->getConfig(Option::remotePhpBinaryPath), + $this->getConfig(Option::remoteComposerBinaryPath), + $this->getConfig(Option::composerOptimizeFlags) + ) + ); } private function doCreateSymlink(): void