Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/jmrecodes/wazzup-news-aggregator-api
Wazzup News Aggregator API
https://github.com/jmrecodes/wazzup-news-aggregator-api
api design-patterns docker laravel laravel-testing pestphp php phpunit psr-12 restful-api sanctum
Last synced: about 2 months ago
JSON representation
Wazzup News Aggregator API
- Host: GitHub
- URL: https://github.com/jmrecodes/wazzup-news-aggregator-api
- Owner: jmrecodes
- Created: 2024-11-09T04:52:25.000Z (about 2 months ago)
- Default Branch: main
- Last Pushed: 2024-11-13T06:04:21.000Z (about 2 months ago)
- Last Synced: 2024-11-13T06:25:33.833Z (about 2 months ago)
- Topics: api, design-patterns, docker, laravel, laravel-testing, pestphp, php, phpunit, psr-12, restful-api, sanctum
- Language: PHP
- Homepage: http://localhost:7700/api/documentation
- Size: 219 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Steps to setup on local machine:
1. Place .env file to the root dir or you can use .env.example by running cp .env.example .env (News Aggregation task scheduled commands won't work this way due to lacking the API keys to authenticate the calls)
2. Open terminal on the root dir
3. Run docker compose build --no-cache && docker compose up -d
4. docker compose exec app composer install
5. docker compose exec app php artisan key:generate
6. docker compose exec app php artisan --env=testing key:generate
7. docker compose exec app php artisan migrate:fresh --seed
8. touch database/testing.sqlite
9. docker compose exec \
-e DB_CONNECTION=sqlite \
-e DB_DATABASE=/var/www/html/database/testing.sqlite \
app php artisan test --env=testing
10. docker compose exec app php artisan schedule:work (need authenticated API keys to work)
11. visit: http://localhost:7700 or http://localhost:7700/api/documentation