pizza-api is the REST API application for CRUD pizzas and set the prices
-
Clone this repo.
-
Composer install
docker-compose run --rm php-cli composer install
-
Up the migrations
docker-compose run --rm php-cli php bin/console doc:mi:mi
-
Load fixtures [optional]
docker-compose run --rm php-cli php bin/console doc:fixtures:load
-
Generate SSL keys
docker-compose run --rm php-cli php bin/console lexik:jwt:generate-keypair
-
First up docker
docker-compose up -d
-
First send for obtain a token
POST http://localhost:8080/api/login_check
{"username":"[email protected]","password":"admin"}
You will receive something like:
- Use this token as Bearer in Headers for requests
- Api documents is available here
http://localhost:8080/api/doc
- Unit tests
docker-compose run --rm php-cli php bin/phpunit