mirror of
https://github.com/laravel/valet.git
synced 2026-02-05 08:30:07 +01:00
Fix for issue #250 - brew package nginx-full not properly recognized as a valid nginx installation
This commit is contained in:
@@ -45,6 +45,17 @@ function hasInstalledPhp()
|
||||
|| $this->installed('php56');
|
||||
}
|
||||
|
||||
/**
|
||||
* Determine if a compatible nginx version is Homebrewed.
|
||||
*
|
||||
* @return bool
|
||||
*/
|
||||
function hasInstalledNginx()
|
||||
{
|
||||
return $this->installed('nginx')
|
||||
|| $this->installed('nginx-full');
|
||||
}
|
||||
|
||||
/**
|
||||
* Ensure that the given formula is installed.
|
||||
*
|
||||
|
||||
@@ -37,7 +37,9 @@ function __construct(Brew $brew, CommandLine $cli, Filesystem $files,
|
||||
*/
|
||||
function install()
|
||||
{
|
||||
$this->brew->ensureInstalled('nginx', ['--with-http2']);
|
||||
if (!$this->brew->hasInstalledNginx()) {
|
||||
$this->brew->installOrFail('nginx', ['--with-http2']);
|
||||
}
|
||||
|
||||
$this->installConfiguration();
|
||||
$this->installServer();
|
||||
|
||||
Reference in New Issue
Block a user