Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use remotePhpBinaryPath when run composer #92

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 23 additions & 3 deletions src/Deployer/DefaultDeployer.php
Original file line number Diff line number Diff line change
Expand Up @@ -337,11 +337,24 @@ private function doInstallDependencies(): void
{
if (true === $this->getConfig(Option::updateRemoteComposerBinary)) {
$this->log('<h2>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('<h2>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
Expand Down Expand Up @@ -390,7 +403,14 @@ private function doClearControllers(): void
private function doOptimizeComposer(): void
{
$this->log('<h2>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
Expand Down