You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+10-12Lines changed: 10 additions & 12 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -57,24 +57,22 @@ Update the file `boostrap/start.php` under the section `Detect The Application E
57
57
58
58
-----
59
59
60
-
*IMPORTANT*: Since the initial install is done via command line (which cannot grok your apache hostname), it's important
61
-
to include your machine name in the environmental array, or to pass the environmental override as a command line argument (using ` --env=local`).
62
-
Otherwise, your configs will default to production (as Laravel does).
60
+
__AS OF LARAVEL 4.1__
61
+
Per the [Laravel 4.1 upgrade docs](http://laravel.com/docs/upgrade):
63
62
64
-
To find out your local machine's hostname, type `hostname` from a terminal prompt on the machine you're installing it on. If you
65
-
encounter an error on your install, saying that the `driver` variable isn't defined, something got botched in your
66
-
environmental settings and it's defaulting to production.
63
+
__*"For security reasons, URL domains may no longer be used to detect your application environment. These values are easily spoofable and allow attackers to modify the environment for a request. You should convert your environment detection to use machine host names (hostname command on Mac & Ubuntu)."*__
67
64
68
-
So for example, if you're installing this locally on your Mac named SnipeMBP and with a local Apache hostname of http://snipe-it.local:8888,
69
-
your environmental variable section of `bootstrap/start.php` might look like this:
65
+
To find out your local machine's hostname, type `hostname` from a terminal prompt on the machine you're installing it on. The command-line response is that machine's hostname. Please note that the hostname is NOT always the same as the domain name.
70
66
71
-
$env = $app->detectEnvironment(array(
67
+
So for example, if you're installing this locally on your Mac named SnipeMBP, the environmental variable section of `bootstrap/start.php` might look like this:
If your development, staging and production sites all run on the same server (which is generally a terrible idea), [see this example](http://words.weareloring.com/development/setting-up-multiple-environments-in-laravel-4-1/) of how to configure the app using environmental variables.
0 commit comments