Weave Code
Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message
Moonshine Roles Permissions

Moonshine Roles Permissions Laravel Package

sweet1s/moonshine-roles-permissions

A Laravel package for managing roles and permissions in MoonShine admin panels. It provides a ready-to-use interface to assign roles, configure permissions, and control access to resources and sections.

View on GitHub
Deep Wiki
Context7

RBAC (Role-Based Access Control) in Laravel Moonshine Admin Panel

Frequently asked questions about Moonshine Roles Permissions
How do I install sweet1s/moonshine-roles-permissions in a Laravel MoonShine project?
Install it with Composer alongside a Moonshine 4.x application, then publish the package config and migrations and run the migrations. Seed an initial super-admin role so you can reach the role and permission screens. The package is only useful when Moonshine is already your admin layer, so treat that as a prerequisite before installing.
Does sweet1s/moonshine-roles-permissions use spatie/laravel-permission?
The package sits in the RBAC layer for MoonShine, and the dominant pattern for this class of package is to wrap spatie/laravel-permission rather than implement authorization from scratch. That dependency is not confirmed in the available material, so check composer.json before adopting it. If spatie/laravel-permission is required, pin a compatible major version because a mismatch can cause permission checks to fail silently.
Which Laravel and MoonShine versions does moonshine-roles-permissions support?
Release 4.0.0 exists specifically to add MoonShine v4 support, and the package appears to use lockstep versioning where its major version tracks the Moonshine major version. The exact Composer constraints are not documented in the provided notes, so inspect composer.json to see whether 4.0.0 allows only Moonshine ^4.0 or also v3. Target PHP 8.1+ and a currently supported Laravel major for a sensible baseline.
How do I upgrade from version 3.0.0 to 4.0.0 with existing role data?
Treat this as a coordinated upgrade with Moonshine, not a standalone package bump: move Moonshine to v4 first, then update the package, or verify the constraints permit one atomic Composer update. Take a database snapshot of roles, permissions, model_has_roles, and model_has_permissions before migrating, then diff row counts and pivot contents afterward. The 4.0.0 changelog is a single line and gives no migration guide, so assume nothing about config, migration, or permission-naming changes until you verify them.
Can I use moonshine-roles-permissions with Filament or Laravel Nova?
No. The package's value is entirely in its MoonShine resource classes and admin UI wiring, so applications using Filament, Nova, or a custom admin panel get nothing from it. If you are not committed to Moonshine as your admin layer, use spatie/laravel-permission directly or a Filament or Nova-specific RBAC package instead.
How does the package control access to MoonShine resources and sections?
It provides a ready-to-use interface for assigning roles and configuring permissions, and those permissions are then used to gate access to Moonshine resources and sections. The practical integration point is the Moonshine resource classes plus the underlying permission engine. Verify the exact permission naming convention before relying on it in production policies.
Is there a test suite and CI for moonshine-roles-permissions?
The available evaluation does not confirm a CI pipeline or a test suite that runs against multiple Laravel and PHP versions. Before adopting it in an authorization path, check the repository for GitHub Actions workflows and tests. If coverage is thin, add your own feature tests around role assignment and access denial.
What are the production risks of using this package for admin authorization?
The headline risk is that it is a single-maintainer, small-org dependency sitting in the authorization path of your admin panel. It is also lockstep-coupled to Moonshine, so a lag in a package release can block a Moonshine major upgrade, and the 4.0.0 changelog gives no indication of whether 3.x still receives security fixes. Review the code and pin versions before putting it in front of production admin users.
What is the maintenance status of SWEET1S and moonshine-roles-permissions?
The package is authored by one contributor under a small GitHub organization, and the changelog is written in Russian, which suggests documentation and issue triage may be primarily non-English. There is no stated commitment to patching the 3.x line after 4.0.0. Ask the maintainer directly about long-term support before making it a hard dependency.
What should I check before adopting moonshine-roles-permissions?
Confirm the Composer constraints for Moonshine and spatie/laravel-permission, and check whether 4.0.0 changed published config, migrations, or permission naming. Look for CI and tests, and decide whether you need an upgrade path for existing role data. If any of those answers are unclear, prototype in a staging copy with a database snapshot before touching production.
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
middlewares/firewall
qubiqx/montapacking
nyoncode/laravel-package-console
pnscripts/filament-broadquill-lite
pnscripts/laravel-sentfold-lite
vleap/mx-sdk-laravel-internal
twidpay/utils
htetmyathlaing/scout-elasticsearch-driver
artisan-toolbox/front-awesome
ls/client-assistant
users-au/laravel-client
cgv/localized-resource
noith/settings
kda/laravel-package
kda/filament-dynamic-navigation
bypersoft/signbox
pairus/product-data
fayne/laravel-filament-cms-core
nodisrupt/laravel-agent
sierratecnologia/media-manager