Installation
The Lumen framework has a few system requirements. Of course, all of these requirements are satisfied by the Laravel Homestead virtual machine, so it's highly recommended that you use Homestead as your local Lumen development environment.
However, if you are not using Homestead, you will need to make sure your server meets the following requirements:
- PHP >= 7.1.3
- OpenSSL PHP Extension
- Mbstring PHP Extension
Lumen utilizes to manage its dependencies. So, before using Lumen, make sure you have Composer installed on your machine.
Via Lumen Installer
First, download the Lumen installer using Composer:
Make sure to place the directory in your PATH so the lumen
executable can be located by your system.
Via Composer Create-Project
You may also install Lumen by issuing the Composer create-project
command in your terminal:
To serve your project locally, you may use the Laravel Homestead virtual machine, , or the built-in PHP development server:
Application Key
The next thing you should do after installing Lumen is set your application key to a random string. Typically, this string should be 32 characters long. The key can be set in the .env
environment file. If you have not renamed the .env.example
file to , you should do that now. If the application key is not set, your user encrypted data will not be secure!