下的Symfony 2(最新版本),我試圖更新我的實體:無法更新實體
php app/console doctrine:schema:upate --force
我得到這個錯誤信息到我的終端:
[Symfony的\組件\配置\定義\異常\ InvalidConfigurationException]
無法識別的選項 「0,1,2,3」 下的 「security.firewalls.access_control」
我是Symfony中的新成員,我不知道在哪裏可以搜索來解決此問題。
這是security.yml文件:
# To get started with security, check out the documentation:
http://symfony.com/doc/current/book/security.html
安全: 編碼器: FOS \ UserBundle \型號\的UserInterface:bcrypt
role_hierarchy:
ROLE_ADMIN: ROLE_USER
ROLE_SUPER_ADMIN: ROLE_ADMIN
# http://symfony.com/doc/current/book/security.html#where-do-users-come-from-user-providers
providers:
fos_userbundle:
id: fos_user.user_provider.username
firewalls:
# disables authentication for assets and the profiler, adapt it according to your needs
main:
pattern: ^/
form_login:
provider: fos_userbundle
csrf_provider: security.csrf.token_manager # Use form.csrf_provider instead for Symfony <2.4
logout: true
anonymous: true
dev:
pattern: ^/(_(profiler|wdt)|css|images|js)/
security: false
#main:
#anonymous: ~
# activate different ways to authenticate
# http_basic: ~
# http://symfony.com/doc/current/book/security.html#a-configuring-how-your-users-will-authenticate
# form_login: ~
# http://symfony.com/doc/current/cookbook/security/form_login_setup.html
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 }