PHPackages                             twinpeaks/user-bundle - 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. twinpeaks/user-bundle

ActiveSymfony-bundle

twinpeaks/user-bundle
=====================

FOSUserBundle extension with admin for use with Symfony2

11341PHP

Since Apr 7Pushed 12y ago3 watchersCompare

[ Source](https://github.com/omarmilhouse/TPUserBundle)[ Packagist](https://packagist.org/packages/twinpeaks/user-bundle)[ RSS](/packages/twinpeaks-user-bundle/feed)WikiDiscussions master Synced 2mo ago

READMEChangelogDependenciesVersions (1)Used By (0)

TPUserBundle
============

[](#tpuserbundle)

FOSUserBundle extension with admin gui

\##Installation

Add TPUserBundle in your composer.json, TPUserBundle require also FOSUserBundle:

```
{
    "require": {
        "friendsofsymfony/user-bundle": "~2.0@dev",
        "twinpeaks/user-bundle": "dev-master"
    }
}
```

Enable the bundle in the kernel:

```
// app/AppKernel.php

public function registerBundles()
{
    $bundles = array(
        // ...
        new FOS\UserBundle\FOSUserBundle(),
        new Knp\Bundle\PaginatorBundle\KnpPaginatorBundle(),
        new Twinpeaks\UserBundle\TPUserBundle(),
    );
}
```

Configure your application's security.yml

```
# app/config/security.yml
security:
    encoders:
        FOS\UserBundle\Model\UserInterface: sha512

    role_hierarchy:
        ROLE_USER:        ROLE_USER
        ROLE_ADMIN:       [ROLE_USER]
        ROLE_SUPER_ADMIN: [ROLE_USER, ROLE_ADMIN, ROLE_ALLOWED_TO_SWITCH]

    providers:
        fos_userbundle:
            id: fos_user.user_provider.username
        in_memory:
            memory:
                users:
                    user:  { password: user, roles: [ 'ROLE_USER' ] }
                    admin: { password: admin, roles: [ 'ROLE_ADMIN' ] }

    firewalls:
        main:
            pattern: ^/
            form_login:
                #login_path: /
                provider: fos_userbundle
                csrf_provider: form.csrf_provider
            logout:       true
            anonymous:    true

    access_control:
        - { path: ^/login$, role: IS_AUTHENTICATED_ANONYMOUSLY }
        - { path: ^/register, role: IS_AUTHENTICATED_ANONYMOUSLY }
        - { path: ^/resetting, role: IS_AUTHENTICATED_ANONYMOUSLY }
        - { path: ^/admin, role: ROLE_ADMIN }
```

Configure the FOSUserBundle

```
# app/config/config.yml

# FOSUser Configuration
fos_user:
    db_driver: orm
    firewall_name: main
    user_class: Twinpeaks\UserBundle\Entity\User
    group:
        group_class: Twinpeaks\UserBundle\Entity\UserGroup
```

Add TPUserBundle to assetic

```
# app/config/config.yml
    bundles:        [ "TPUserBundle" ]
```

Import routing files

```
# app/config/routing.yml
twinpeaks_user:
    resource: "@TPUserBundle/Resources/config/routing.xml"
    prefix:   /admin

fos_user_security:
    resource: "@FOSUserBundle/Resources/config/routing/security.xml"

fos_user_profile:
    resource: "@FOSUserBundle/Resources/config/routing/profile.xml"
    prefix: /profile

fos_user_register:
    resource: "@FOSUserBundle/Resources/config/routing/registration.xml"
    prefix: /register

fos_user_resetting:
    resource: "@FOSUserBundle/Resources/config/routing/resetting.xml"
    prefix: /resetting

fos_user_change_password:
    resource: "@FOSUserBundle/Resources/config/routing/change_password.xml"
    prefix: /profile
```

Update the schema database

```
#console
php app/console doctrine:schema:update --force
```

Create user

```
#console
php app/console fos:user:create
```

Promote user to SuperAdmin Create user

```
#console
php app/console fos:user:promote username ROLE_SUPER_ADMIN
```

###  Health Score

22

—

LowBetter than 22% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity12

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity41

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 92.3% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

### Community

---

Top Contributors

[![omarmilhouse](https://avatars.githubusercontent.com/u/1949935?v=4)](https://github.com/omarmilhouse "omarmilhouse (12 commits)")[![bionicvapourboy](https://avatars.githubusercontent.com/u/1949975?v=4)](https://github.com/bionicvapourboy "bionicvapourboy (1 commits)")

### Embed Badge

![Health badge](/badges/twinpeaks-user-bundle/health.svg)

```
[![Health](https://phpackages.com/badges/twinpeaks-user-bundle/health.svg)](https://phpackages.com/packages/twinpeaks-user-bundle)
```

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
