- Docker 🐳
- Clone the repository and go to
expenses
directory:
git clone https://github.com/thiiagoms/laravel-expenses-api expenses
cd expenses
- Setup containers and install dependencies inside app container:
docker-compose up -d
docker-compose exec app bash
thiiagoms@e795fc12781f:/var/www$ composer install
- Copy
.env.example
to.env
and generate application key:
thiiagoms@e795fc12781f:/var/www$ cp .env.example .env
thiiagoms@e795fc12781f:/var/www$ php artisan key:generate
- Run migrations and setup queue:
thiiagoms@e795fc12781f:/var/www$ php artisan migrate
thiiagoms@e795fc12781f:/var/www$ php artisan queue:work
- Generate swagger docs:
thiiagoms@e795fc12781f:/var/www$ php artisan l5-swagger:generate
- Go to:
-
http://localhost:8000/api/documentation
- to see swagger docs -
http://localhost:8000/api
- to use application
- To run tests and lint:
thiiagoms@e795fc12781f:/var/www$ php artisan tests
thiiagoms@e795fc12781f:/var/www$ composer pint app tests