Changed environment checking to use HTTP_HOST instead of SERVER_NAME to resolve an issue with nginx server_name variable. Updated jarring to skip any files prefixed with '.' so that I could edit core files and not generate munged jar files because of vi .swp files.
This commit is contained in:
parent
3ea9ec8f36
commit
dbcf6fdb80
3 changed files with 7 additions and 1204 deletions
|
@ -131,7 +131,9 @@ class Config extends Object
|
|||
}
|
||||
else
|
||||
{
|
||||
if ((preg_match('/^\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}$/', $host) && $_SERVER['SERVER_ADDR'] == $host) || $_SERVER['SERVER_NAME'] == $host)
|
||||
if ((preg_match('/^\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}$/', $host)
|
||||
&& $_SERVER['SERVER_ADDR'] == $host)
|
||||
|| $_SERVER['HTTP_HOST'] == $host)
|
||||
{
|
||||
// Sets the environment and makes a run for it
|
||||
$environment = $name;
|
||||
|
|
|
@ -63,7 +63,7 @@ function readFileContents($directory)
|
|||
|
||||
foreach ($files as $file)
|
||||
{
|
||||
if (!in_array($file, array('.', '..')))
|
||||
if (strpos($file, '.') != 0)
|
||||
{
|
||||
$file = $directory . '/' . $file;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue