I am using laravel 5.2 to develop app.
As of now I am using php -S localhost:8888 -t public
to deploy the test development app.
I know that I have to change configuration file .env for production.
But itseams I can't use php artisan serve
or php -S localhost:8888 -t public
to deploy the app as production app.
I am using WAMP in my machine. Currently I placed my laravel app in C:\wamp\www\laravel
.
What are the correct steps to deploy my laravel 5.2 app?
php artisan serve
creates a local, development, very basic HTTP server and is not for production. It won't handle more than a handful of visits and will break quickly, and isn't secured in the way Apache or Nginx are.
Based on your directory path C:\wamp\www\laravel
, I guess you are using a WAMP server? The A in WAMP is Apache - the web server you use instead of php artisan serve
.
Setting up the site on a production server will vary based on your setup, but the general steps will look like:
composer install
to install the dependencies..env
file.Ensure that WAMP is running and the site is configured and you should should be good to go.
If you don't have much server experience and just want to securely and simply host a Laravel app, I would strongly suggest checking our Laravel Forge - it does everything and your site will be on the public Internet within 10 minutes.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With