PHPackages                             tendoo/cloud-breeze - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. tendoo/cloud-breeze

ActiveLibrary

tendoo/cloud-breeze
===================

A bunch of useful features to start creating PWA with Laravel.

v5.0.5(6y ago)3383[1 issues](https://github.com/Tendoo/cloud-breeze/issues)[29 PRs](https://github.com/Tendoo/cloud-breeze/pulls)MITPHPPHP &gt;=7.2.0

Since Mar 19Pushed 3y ago2 watchersCompare

[ Source](https://github.com/Tendoo/cloud-breeze)[ Packagist](https://packagist.org/packages/tendoo/cloud-breeze)[ RSS](/packages/tendoo-cloud-breeze/feed)WikiDiscussions api-server Synced today

READMEChangelog (10)Dependencies (10)Versions (41)Used By (0)

[![Build Status](https://camo.githubusercontent.com/4b4ee38b8af6b7137ba80c24b5097035bcaea546a2e5224c5840f60489aaeee1/68747470733a2f2f7472617669732d63692e6f72672f54656e646f6f2f636d732e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/Tendoo/cms)[![Total Downloads](https://camo.githubusercontent.com/38e00defbabbb298e0518cd5a9bcf93d676d25d8b278847e80981174461ac952/68747470733a2f2f706f7365722e707567782e6f72672f74656e646f6f2f636d732f642f746f74616c2e737667)](https://packagist.org/packages/tendoo/cms)[![Latest Stable Version](https://camo.githubusercontent.com/562dd25021f00e2f28a895341910851b176c3aa7e59b85e7a65bb6caf142dc7b/68747470733a2f2f706f7365722e707567782e6f72672f74656e646f6f2f636d732f762f737461626c652e737667)](https://packagist.org/packages/tendoo/cms)[![License](https://camo.githubusercontent.com/42958c3eccc1457dd1dbd4b10119941fe82e26154bca979d33e7f19f7d01648d/68747470733a2f2f706f7365722e707567782e6f72672f74656e646f6f2f636d732f6c6963656e73652e737667)](https://packagist.org/packages/tendoo/cms)

[Internal Screenshots](https://github.com/Tendoo/cloud-breeze/wiki/Internal-Screenshots)

Cloud Breeze : Why this new project
===================================

[](#cloud-breeze--why-this-new-project)

This package has been create to extend laravel to a modulable Framework. Usually for Laravel, most of the time only one application is created per installation. If the application is huge, it might consist into small several features that are somehow linked together. While this might work for anyone willing to create a single application, it becomes more hard when it comes to create a very large ecosystem with a bunch of differents features that might not be at all related.

Cloud Breeze ensure you to have a moduleable system with (obviously) modules, that has their own and isolated entities : Controllers, Api &amp; Web routes, Migrations, Service Providers, Email, Views... It comes with some extra features on top of the one already provided by Laravel to ease the developpment as much as possible.

- Dedicated Authentication Pages (registration, login, recovery)
- Dedicated Dashboard
    - User Management
    - Options Management
    - Media Management (images...)
    - Modules Management (install, enable, disable)
    - Applications Management (Let you define API keys for secured API endpoints).
- Oauth Enpoints

These are provided with on the laravel package extensions. However, we have decoupled the ui from the backend and so, you can invoke (import) some of the frontend elements such as:

- Fields,
- ValidationGenerator
- AuthService
- CoreService
- FieldsServices
- FormsServices
- Crud Component
- Dialog Component
- ...

These ensure you to quickly have a working UI that interact directly with Cloud Breeze and all his modules. You should note that the UI of cloud breeze is build with Angular 8, Angular Material and some others dependencies. You can require the package on your environment using npm

`npm i @cloud-breeze/core`

Installation
============

[](#installation)

### Download Package

[](#download-package)

Since Cloud Breeze is a package, it could be installed using a composer command :

`composer require tendoo/cms`

Then, you need to publish the assets of Cloud Breeze by running the following command :

`php artisan tendoo:publish`

It's important to publish the assets, since the system need to save on the database your current Cloud Breeze version. This will be helpful, to know exaclty when to perform an update.

### Create Storage Disks

[](#create-storage-disks)

You need to update your filesystems.php file available on the config directory with the following changes :

```
'disks' => [
  // ...

    'cb-root'       =>  [
        'driver'    =>  'local',
        'root'      =>  base_path()
    ],

  // ...
],
```

Updating the filesystems will allow Cloud Breeze to save modules and to publish useful assets correctly.

### Register EncryptCookies Middleware

[](#register-encryptcookies-middleware)

By default, the cookies registered by Cloud Breeze will be encrypted. With that, Cloud Breeze won't be able to authenticate and remember the user authenticated from the login UI provided. You need to register the middleware on the Kernel.php. If you have any specific cookie excaped from the middleware `App\Http\Middleware\EncryptCookies` it will be used on `Tendoo\Core\Http\Middleware\EncryptCookies`. You'll then comment (or delete) the default middleware on `app\Http\Kernel.php` like so :

```
// something before...
protected $middlewareGroups = [
    'web' => [
        // \App\Http\Middleware\EncryptCookies::class,  [
    'enable'        =>  true,

    /**
     * describe what is forbidden
     * on each request processed
     */
    'forbidden'     =>  [
        '.php',
    ],

    /**
     * if a client makes the same mistake
     * "x" times, his ip will be banned
     */
    'mistakes-threshold'    =>  1,

    /**
     * the ip of the client
     * will be recorded
     * on the mentionned htaccess file
     */
    'htaccess-blocking'     =>  false,

    'htaccess-path'         =>  ''
],
```

For the anti-flood request, you just need to mention how many requests per minutes a client can make. Here is how it looks like :

```
'flood'             =>  [
    'prevent'       =>  false, // should be enabled
    'limit'         =>  30,
    'expiration'    =>  60
],
```

API
===

[](#api)

This describe how the internal API works.

Users Permissions &amp; Roles
-----------------------------

[](#users-permissions--roles)

A role allow you to group users whom should have the same attributes. For example, you could have a editor role on your system, if for example you're planning to create blog where such role will be needed. Once a role is created, you can assign permission to it. A permission is the capacity to perform an action on the system. Assigning a permissions is not the only step as you need to verify if a user has the permission to perform certains actoin through his role.

### Creating Role

[](#creating-role)

Creating a role is possible thanks to the class `Tendoo\Core\Models\Role`. A role has a name, and a `namespace` which is more like a computer identifier for the entity. Let's consider the following example :

```
