Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/brefphp/dev-server
Local development server for serverless web apps
https://github.com/brefphp/dev-server
bref
Last synced: 2 days ago
JSON representation
Local development server for serverless web apps
- Host: GitHub
- URL: https://github.com/brefphp/dev-server
- Owner: brefphp
- License: mit
- Created: 2020-12-26T17:39:34.000Z (almost 4 years ago)
- Default Branch: master
- Last Pushed: 2024-04-16T11:20:36.000Z (7 months ago)
- Last Synced: 2024-10-31T12:23:42.048Z (11 days ago)
- Topics: bref
- Language: PHP
- Homepage: https://bref.sh/docs/function/local-development.html#api-gateway-local-development
- Size: 22.5 KB
- Stars: 36
- Watchers: 3
- Forks: 8
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
- Contributing: .github/CONTRIBUTING.md
- Funding: .github/FUNDING.yml
- License: LICENSE
Awesome Lists containing this project
README
Development web server for serverless-native PHP web apps.
## Why?
This web server is meant for HTTP applications implemented without framework, using API Gateway as the router and PSR-15 controllers.
## Installation
```bash
composer require --dev bref/dev-server
```## Usage
Run the webserver with:
```bash
vendor/bin/bref-dev-server
```The application will be available at [http://localhost:8000/](http://localhost:8000/).
Routes will be parsed from `serverless.yml` in the current directory.
### Assets
By default, static assets are served from the current directory.
To customize that, use the `--assets` option. For example to serve static files from the `public/` directory:
```bash
vendor/bin/bref-dev-server --assets=public
```