mirror of
https://github.com/usetrmnl/byos_laravel.git
synced 2026-01-13 15:07:49 +00:00
fix: status code while setup; chore: update readme
This commit is contained in:
parent
dff61f85dd
commit
60f8899960
2 changed files with 38 additions and 32 deletions
41
README.md
41
README.md
|
|
@ -1,4 +1,4 @@
|
|||
## Laravel Trmnl Server
|
||||
## TRMNL BYOS (PHP/Laravel)
|
||||
|
||||
Laravel Trmnl Server is a self-hostable implementation of a TRMNL server, built with Laravel.
|
||||
It enables you to manage TRMNL devices, generate screens dynamically, and can act as a proxy for the TRMNL API (native plugin system).
|
||||
|
|
@ -25,6 +25,8 @@ This project is for developers who are looking for a self-hosted server for devi
|
|||
It serves as a starter kit, giving you the flexibility to build and extend it however you like.
|
||||
|
||||
### Support ❤️
|
||||
This repo is maintained voluntarily by [@bnussbau](https://github.com/bnussbau).
|
||||
|
||||
Support the development of this package by purchasing a TRMNL device through our referral link: https://usetrmnl.com/?ref=laravel-trmnl. At checkout, use the code `laravel-trmnl` to receive a $15 discount on your purchase.
|
||||
|
||||
### Requirements
|
||||
|
|
@ -88,6 +90,7 @@ volumes:
|
|||
| `TRMNL_PROXY_BASE_URL` | Base URL of the native TRMNL service | https://trmnl.app |
|
||||
| `TRMNL_PROXY_REFRESH_MINUTES` | How often should the server fetch new images from native service | 15 |
|
||||
| `REGISTRATION_ENABLED` | Allow user registration via Webinterface | 1 |
|
||||
| `FORCE_HTTPS` | If your server handles SSL termination, enforce HTTPS. | 0 |
|
||||
|
||||
#### Login
|
||||
|
||||
|
|
@ -209,24 +212,6 @@ Schedule::command('plugin:train:fetch')
|
|||
|
||||
This will automatically update the screen every 5 minutes between 5:00 AM and 6:00 PM local time.
|
||||
|
||||
### 🤝 Contribution
|
||||
Contributions are welcome! If you’d like to improve the project, follow these steps:
|
||||
|
||||
1. Open an Issue
|
||||
- Before submitting a pull request, create an issue to discuss your idea.
|
||||
- Clearly describe the feature or bug fix you want to work on.
|
||||
2. Fork the Repository & Create a Branch
|
||||
3. Make Your Changes & Add Tests
|
||||
- Ensure your code follows best practices.
|
||||
- Add Pest tests to cover your changes.
|
||||
4. Run Tests
|
||||
- `php artisan test`
|
||||
5. Submit a Pull Request (PR)
|
||||
- Push your branch and create a PR.
|
||||
- Provide a clear description of your changes.
|
||||
|
||||
🚀 Thank you for contributing! Every contribution helps improve the project.
|
||||
|
||||
### 🏗️ Roadmap
|
||||
|
||||
Here are some features and improvements that are open for contribution:
|
||||
|
|
@ -257,6 +242,24 @@ Here are some features and improvements that are open for contribution:
|
|||
- Expand Pest tests to cover more functionality.
|
||||
- Increase code coverage (currently at 86.9%).
|
||||
|
||||
### 🤝 Contribution
|
||||
Contributions are welcome! If you’d like to improve the project, follow these steps:
|
||||
|
||||
1. Open an Issue
|
||||
- Before submitting a pull request, create an issue to discuss your idea.
|
||||
- Clearly describe the feature or bug fix you want to work on.
|
||||
2. Fork the Repository & Create a Branch
|
||||
3. Make Your Changes & Add Tests
|
||||
- Ensure your code follows best practices.
|
||||
- Add Pest tests to cover your changes.
|
||||
4. Run Tests
|
||||
- `php artisan test`
|
||||
5. Submit a Pull Request (PR)
|
||||
- Push your branch and create a PR.
|
||||
- Provide a clear description of your changes.
|
||||
|
||||
🚀 Thank you for contributing! Every contribution helps improve the project.
|
||||
|
||||
### License
|
||||
MIT
|
||||
|
||||
|
|
|
|||
|
|
@ -68,8 +68,9 @@ Route::get('/setup', function (Request $request) {
|
|||
|
||||
if (! $mac_address) {
|
||||
return response()->json([
|
||||
'status' => '404',
|
||||
'message' => 'MAC Address not registered',
|
||||
], 400);
|
||||
], 404);
|
||||
}
|
||||
|
||||
$device = Device::where('mac_address', $mac_address)->first();
|
||||
|
|
@ -90,6 +91,7 @@ Route::get('/setup', function (Request $request) {
|
|||
]);
|
||||
} else {
|
||||
return response()->json([
|
||||
'status' => '404',
|
||||
'message' => 'MAC Address not registered or invalid access token',
|
||||
], 404);
|
||||
}
|
||||
|
|
@ -114,6 +116,7 @@ Route::post('/log', function (Request $request) {
|
|||
|
||||
if (! $device) {
|
||||
return response()->json([
|
||||
'status' => '404',
|
||||
'message' => 'Device not found or invalid access token',
|
||||
], 404);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue