Laravel 9 Template
Just a empty Laravel 9 project, ready to start new crap.
Clone and start using.
Usage - Local Env
The same as usual with laravel.
Clone, make a .env file, and then:
composer install
php artisan keys:generate
php artisan migrate
php artisan serve
Usage - Docker
Quickstart
Because we don't like to read, we just want to run this shit on a system with docker and docker-compose installed.
First, copy the .env.example file into .env, and make sure that has this values:
DB_CONNECTION=mysql
DB_HOST=mysql
DB_PORT=3306
DB_DATABASE=laravel
DB_USERNAME=root
DB_PASSWORD=1234
Then, where you cloned the project:
- For running in foreground (and view logs):
docker-compose up
- For running in background (f*ck the logs):
docker-compose up
Details
If using docker, find a image that solve that for you. There are millions. But mine is better, because is mine: ggmartinez/laravel:9-php7-Xdebug
This repository includes a wonderful docker-compose.yml
file to make the world a better place.
It is all configured to do magic. It mounts the project into the /app
folder inside the container (my image starts laravel there), installs composer packages, run migrations, and starts Laravel.
Also, it brings up a MySQL 5.7 database. Just copy .env.example into .env, and add this to the .env file before running everything:
DB_CONNECTION=mysql
DB_HOST=mysql
DB_PORT=3306
DB_DATABASE=laravel
DB_USERNAME=root
DB_PASSWORD=1234
As you can guess,** this is PURELY FOR DEVELOPMENT**, if you want to use this in production, make sure that everything is configured as it should be, or just f*ck the world and live with adrenaline in your blood.
Visutal Studio code Debugging
First, needs this extension: https://marketplace.visualstudio.com/items?itemName=xdebug.php-debug
Then, depending on your environment (local or Docker) need to create a launch.json file.
If using Docker (for example, with my image ggmartinez/laravel:9-php7-Xdebug):
{
"version": "0.2.0",
"configurations": [
{
"name": "XDebug - Laravel on Docker",
"type": "php",
"request": "launch",
"port": 9003
,
"pathMappings": {
"/app": "${workspaceFolder}/"
},
}
]
}
If not using Docker:
{
"version": "0.2.0",
"configurations": [
{
"name": "XDebug - Laravel on Docker",
"type": "php",
"request": "launch",
"port": 9003
}
]
}
Laravel Stuff
Now, the rest of the original Laravel Readme
About Laravel
Laravel is a web application framework with expressive, elegant syntax. We believe development must be an enjoyable and creative experience to be truly fulfilling. Laravel takes the pain out of development by easing common tasks used in many web projects, such as:
- Simple, fast routing engine.
- Powerful dependency injection container.
- Multiple back-ends for session and cache storage.
- Expressive, intuitive database ORM.
- Database agnostic schema migrations.
- Robust background job processing.
- Real-time event broadcasting.
Laravel is accessible, powerful, and provides tools required for large, robust applications.
Learning Laravel
Laravel has the most extensive and thorough documentation and video tutorial library of all modern web application frameworks, making it a breeze to get started with the framework.
If you don't feel like reading, Laracasts can help. Laracasts contains over 1500 video tutorials on a range of topics including Laravel, modern PHP, unit testing, and JavaScript. Boost your skills by digging into our comprehensive video library.
Laravel Sponsors
We would like to extend our thanks to the following sponsors for funding Laravel development. If you are interested in becoming a sponsor, please visit the Laravel Patreon page.
Premium Partners
- Vehikl
- Tighten Co.
- Kirschbaum Development Group
- 64 Robots
- Cubet Techno Labs
- Cyber-Duck
- Many
- Webdock, Fast VPS Hosting
- DevSquad
- Curotec
- OP.GG
- WebReinvent
- Lendio
Contributing
Thank you for considering contributing to the Laravel framework! The contribution guide can be found in the Laravel documentation.
Code of Conduct
In order to ensure that the Laravel community is welcoming to all, please review and abide by the Code of Conduct.
Security Vulnerabilities
If you discover a security vulnerability within Laravel, please send an e-mail to Taylor Otwell via [email protected]. All security vulnerabilities will be promptly addressed.
License
The Laravel framework is open-sourced software licensed under the MIT license.