GithubHelp home page GithubHelp logo

stagerightlabs / centaur Goto Github PK

View Code? Open in Web Editor NEW
60.0 60.0 25.0 143 KB

An opinionated implementation of Cartalyst's Sentinel package for Laravel

Home Page: http://stagerightlabs.com/projects/centaur

License: MIT License

JavaScript 1.09% PHP 75.06% Blade 23.85%

centaur's Introduction

stagerightlabs.com

CI

This repository houses the home page and blog for Stage Right Labs, LLC.

Local Development

You can use docker to run this application locally:

  1. Build the images:
$ docker-compose build
  1. Install the PHP dependencies:
$ docker-compose run cli composer install
  1. Install the NPM dependencies and build the frontend assets:
$ docker-compose run node npm install
$ docker-compose run node npm run dev
  1. Create your .env file:
$ docker-compose run cli cp .env.example .env
  1. Generate an application key:
$ docker-compose run cli php artisan key:generate
  1. Spin up the containers:
$ docker-compose up -d
  1. The database will be created automatically. You can now run the migrations:
$ docker-compose exec cli php artisan migrate
  1. Generate a backstage user:
$ docker-compose exec cli php artisan backstage:user [email]
  1. Add a new entry to your hosts file:
$ sudo bash -c "echo '127.0.0.1 stagerightlabs.test' >> /etc/hosts"
  1. You should now be able to view the site in your browser by going to http://stagerightlabs.test. You are now off to the races!

Stack

This application is built on the TALL Stack:

We are also making use of these additional tools:

Credits

Special Thanks:

centaur's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

centaur's Issues

Login page redirecting to Dasboard

I have two login page one /admin/login other direct /login and when i hit the /admin/login its redirecting me to /dasboard directly when i'm already logged in
But its should redirect me to admin/dasboard i couldnt find how can i change this why its redirecting me to dashboard

Throttle

How to use throttle from route login attempts and configuration. Thanks.

Allowing users to edit only their own articles

Hi,
I'd like to implement the following access rules for an app where users can post articles, I would like to have an "admin" role and a "user" role, and set up the permissions so that users can create articles, users can edit only the articles that they created, and admins can edit all articles.
In this case, the "admin" role would have an "articles.edit" permission, but I'm not sure how to handle the "user" role.
Does this package provide an out-of-the-box solution for this case?
Thank you in advance.

Activation route redirects to error page

Hi,

Authentication and Authorization works fine until i clicked the Activation link sent to new user email.

On clinking the Activation email line, the page that displayed showed this error

InvalidArgumentException
Route [login] not defined.

I actually want to activation link to redirect to {{route('auth.login.form')}} but kept redirecting to the error page.

I have tried all solutions but none seems not to work

Please kindly advise on what i should do. Thanks

Laravel 8 and Cartalyst 5 support.

It may just need version numbers bumping in composer.json, but with Centaur 10.00.01 I can't upgrade to Laravel 8.

Your requirements could not be resolved to an installable set of packages.

  Problem 1
    - Installation request for srlabs/centaur ^10.0 -> satisfiable by srlabs/centaur[10.0.0, 10.00.01].
    - Can only install one of: cartalyst/sentinel[5.x-dev, 4.x-dev].
    - Can only install one of: cartalyst/sentinel[5.0.x-dev, 4.x-dev].
    - Can only install one of: cartalyst/sentinel[v5.0.0, 4.x-dev].
    - Conclusion: install cartalyst/sentinel 4.x-dev
    - Installation request for cartalyst/sentinel ^5.0 -> satisfiable by cartalyst/sentinel[5.x-dev, 5.0.x-dev, v5.0.0].

Error messages not showing up

I've created a new installation using Laravel 5.2 and srlabs/centaur ^2.0, followed all instructions using artisan commands. Everything work fine but error messages simply won't show. I tried generating error messages by simulating erroneous user input at login, registration and by trying to delete admin account but the system only refreshes the page but won't show any errors.

Delete user and roles is not possible

Hi,

I'm using your fantastic package but I have a weird issue.
I could delete user and roles easily but now it's not working anymore. I'm redirected directly on the controller's index view

I do not change middleware or other.

What do you think ?

Thanks for your time,

Regards

Translate your package

Hello,

I use your package and try to translate it (french).
Middlewares are not translated
AuthManager.php has this : $this->translate('user_logout', 'You have been logged out')

How can I do ?

Thanks

Social login

Is there any way I can use this package to login a user with facebook?

I've already made the logic to get the user details from facebook, but I got stuck at login part. I don't know how to make the login using this package.

any suggestions?

Laravel Passport

Hello,

I'm trying to build API's for a project. However, I'm confused as to how to make this work with L5.3 Passport. I know this issues sounds vague. But a little light towards the right direction might help.

Regards

Need help at upgrading from rydurham/Sentinel

Hi there,

this is not an issue report. I just need some help.

I got an project that was built with laravel 4 and rydurham/Sentinel.
Since Laravel 4 is not very recent anymore it should be updated to the newest possible version.

After reading some warning to not use rydurham/sentinel i decided to use the solution linked from there (this one).

I followed the instructions and it seems to work so far. Not exceptions, the login page works fine.

But there is one thing that breaks it for me. I believe it is a small thing, but i need further information about how it should be.

There is the line: php artisan db:seed --class="SentinelDatabaseSeeder" that should be executed.
But i can't use this, since i have already an user table from the current setup.

Trying to login results in a exception that tells me that there is a column ("type") missing.

So the current user table with the columns (id ,email ,password ,permissions ,activated ,activation_code ,activated_at ,last_login ,persist_code ,reset_password_code ,first_name ,last_name ,company ,master ,global ,created_at ,updated_at) is not compatible to centaur/sentinel.

I also saw that there is a migration script from sentinel. I could let the script recreate all tables (they were empty) except the users table.

So here is my question.
Can i migrate the users table to be compatible with centaur/sentinel?
Or should i better go back to rydurham/sentinel?
Is there a documentation about the users table content? (in order to remap the data)

I am grateful for every help ๐Ÿ‘

Account Not Yet Activated Debug page Change

Hi,

In Centaur, If a Registered user tries to Login before activating himself via email, it's expected that an error message will show as a notification that "Your account has not been activated yet."

Instead of the error message to show as notification, it's showing as a Debug page Application frames.

Please kindly advise me on the steps to take to make the error message show up as Notification rather than Debug page.

Thanks

How can i use correctly remember me

Im trying to use this feature but i just cant know how to implement it since there is no documentation about this.

i know i need to set remember me as true when i authenticate but then what i need to do for the user not need to write his username and/or password again to login.

could someone help me? please

Expected response code 250 but got code "530", with message "530 5.7.1 Authentication required"

I have this issue:

Expected response code 250 but got code "530", with message "530 5.7.1 Authentication required"

this occurred when I follow the basic in the markdown and successfully migrate the database and post a registration form at '/register'.

I use :

  • Laravel 5.4.26
  • "srlabs/centaur": "4.*" (4.0.3)
  • cartalyst/support (v2.0.1) (generated from centaur)
  • cartalyst/sentinel (v2.0.15) (generated from centaur)

Laravel 5.7 release

Hey,
There doesn't seem to be a tag for laravel 5.7 (ie release tagged 7.x.x)
Are you able to create one as there seems the 5.7 support?
Thanks!

Loop after role deletion

We should prevent role ID 1 from being removed but I'm not sure if the problem affects only this ID.

The role is being deleted successfully, then the browser enters in a loop of requests.

imagem

Potential front-end solution:
Add {{ $role->id === 1 ? 'disabled' : '' }} to the delete button.

Using custom User Model

I am facing a problem, i want to use my User model instead of EloquentUser Model, because i want to add more fields, i have already updated the cartalyst.sentinel.php config file

'users' => [

    // 'model' => 'Cartalyst\Sentinel\Users\EloquentUser',
    'model' => 'App\User',

],

And in the User.php model is added
use Cartalyst\Sentinel\Users\EloquentUser as SentinelUser;
class User extends SentinelUser
{
}

But still it is using the EloquentUser model.

Dear Centaur can you please let me know when php 8.0 support will be available?

Dear Centaur can you please let me know when php 8.0 support will be available?

Your requirements could not be resolved to an installable set of packages.

Problem 1
- srlabs/centaur 10.00.01 requires php ^7.2 -> your PHP version (8.0.0) does not satisfy that requirement.
- srlabs/centaur 10.0.0 requires php ^7.2 -> your PHP version (8.0.0) does not satisfy that requirement.
- srlabs/centaur 10.00.01 requires php ^7.2 -> your PHP version (8.0.0) does not satisfy that requirement.
- Installation request for srlabs/centaur ^10.0 -> satisfiable by srlabs/centaur[10.0.0, 10.00.01].

Only mailables may be queued. InvalidArgumentException in Mailer.php line 314:

Error when registering new user (guess it will be the same for any action that sends an email) because Laravel 5.3/5.4 use mailables.

  1. in Mailer.php line 314
  2. at Mailer->queue('centaur.email.welcome', array('code' => 'randomstring', 'email' => '[email protected]'), object(Closure)) in Facade.php line 221
  3. at Facade::__callStatic('queue', array('centaur.email.welcome', array('code' => 'randomstring', 'email' => '[email protected]'), object(Closure))) in UserController.php line 99
  4. at Mail::queue('centaur.email.welcome', array('code' => 'randomstring', 'email' => '[email protected]'), object(Closure)) in UserController.php line 99
  5. at UserController->store(object(Request))
    ...

I'm relatively new to development so don't know how to go about fixing this myself.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.