Page Menu
Home
DevCentral
Search
Configure Global Search
Log In
Files
F11723358
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
1 KB
Referenced Files
None
Subscribers
None
View Options
diff --git a/app/Http/routes.php b/app/Http/routes.php
index db057a8..6808e21 100644
--- a/app/Http/routes.php
+++ b/app/Http/routes.php
@@ -1,32 +1,28 @@
<?php
/*
|--------------------------------------------------------------------------
| Application Routes
|--------------------------------------------------------------------------
|
| Here is where you can register all of the routes for an application.
| It's a breeze. Simply tell Laravel the URIs it should respond to
| and give it the controller to call when that URI is requested.
|
*/
Route::get('/', function () {
return view('welcome');
});
// Allows to external tool to ping your instalation and know if the site is up.
Route::get('/status', function() {
return "ALIVE";
});
-
// Gate controllers
-$controllers = [
- 'GitHub'
-];
-foreach ($controllers as $controller) {
+foreach (Config::get('gate.controllers') as $controller) {
$controllerRoute = '/gate/' . $controller . '/';
Route::get($controllerRoute . '{door?}', "Gate\\${controller}GateController@onGet");
Route::post($controllerRoute . '{door}', "Gate\\${controller}GateController@onPost");
}
diff --git a/config/gate.php b/config/gate.php
new file mode 100644
index 0000000..4be3e88
--- /dev/null
+++ b/config/gate.php
@@ -0,0 +1,19 @@
+<?php
+
+return [
+
+ /*
+ |--------------------------------------------------------------------------
+ | Gate controllers
+ |--------------------------------------------------------------------------
+ |
+ | Notifications center accept payload from several services and calls
+ | matching gate controllers to process messages.
+ |
+ */
+
+ 'controllers' => [
+ 'GitHub',
+ ],
+
+];
File Metadata
Details
Attached
Mime Type
text/x-diff
Expires
Thu, Sep 18, 09:58 (18 h, 8 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2987555
Default Alt Text
(1 KB)
Attached To
Mode
rNOTIF Notifications center
Attached
Detach File
Event Timeline
Log In to Comment