Symfony FOS user bundle initiation

Eakethet picture Eakethet · Feb 7, 2017 · Viewed 16k times · Source

I have a problem with installing FOS user bundle. I tried to search it everywhere, but probably I'm too dumb and can't find it.

I've created an entity called Admin and tried to run doctrine:schema:update --force I've got an error: The child node "from_email" at path "fos_user" must be configured.

Here is my config.yml fos part.

fos_user:
    db_driver: orm # other valid values are 'mongodb' and 'couchdb'
    firewall_name: main
    user_class: AppBundle\Entity\Admin

any suggestions?

Answer

Breith picture Breith · Feb 7, 2017

in your config.yml add from_email at path "fos_user":

# ...
fos_user:
    db_driver: orm # other valid values are 'mongodb' and 'couchdb'
    firewall_name: main
    user_class: AppBundle\Entity\Admin
    # ...
    from_email:
        address: [email protected]
        sender_name: You
# ...

More info : Step 5: Configure the FOSUserBundle