Skip to content

codestudiohq/laravel-totem

Repository files navigation

Laravel Totem

Build Status StyleCI License

Introduction

Laravel Totem is in its Alpha state. Its still a work in progress. Please proceed with caution and on your own risk.

Manage your Laravel Schedule from a pretty dashboard. Schedule your Laravel Console Commands to your liking. Enable/Disable scheduled tasks on the fly without going back to your code again.

Documentation

Installation

Totem requires Laravel v5.5.Use composer to install totem to your Laravel project

composer require studio/laravel-totem

Laravel Totem supports auto package discovery for Laravel v5.5.

Once Laravel Totem is installed , publish Totem assets to your public folder using the following command

php artisan totem:assets

Configuration

Cron Job

This package assumes that you have a good understanding of Laravel's Task Scheduling and Laravel Console Commands. Before any of this works please make sure you have a cron running as follows:

* * * * * php /path-to-your-project/artisan schedule:run >> /dev/null 2>&1
Web Dashboard

Laravel Totem's dashboard is inspired by Laravel Horizon. Just like Horizon you can configure authentication to Totem's dashboard. Add the following to the boot method of your AppServiceProvider or wherever you might seem fit.

Totem::auth(function($request) {
    // return true / false . For e.g.
    return Auth::check()
});

By default Totem's dashboard only works in local environment. To view the dashboard point your browser to /totem of your app. For e.g. laravel.dev/totem.

Making Commands available in Laravel Totem

All available commands can be scheduled. If you want to hide a command from Totem make sure you have the hidden attribute set to true in your command. For e.g.

protected $hidden = true;

Current limitations

Currently tasks can only be scheduled with a cron expression. Stay tuned for more Laravel Schedule like fluent configurations.

Changelog

Important versions listed below. Refer to the Changelog for a full history of the project.

Credits

Bug reports, feature requests, and pull requests can be submitted by following our Contribution Guide.

Contributing & Protocols

License

This software is released under the MIT License.

© 2017 Roshan Gautam, All rights reserved.