controllers: resource: path: ../../src/Controller/ namespace: App\Controller type: attribute prefix: '{_locale}' # OAuth2 protocol endpoints (client registration, discovery metadata) must live at fixed, # spec-mandated paths with no locale prefix - see config/routes/oauth_server_controllers.yaml. exclude: '../../src/Controller/OAuth/*' defaults: _locale: '%kernel.default_locale%' requirements: # Match only locales like de_DE or de _locale: "^[a-z]{2}(_[A-Z]{2})?$" oauth_server_controllers: resource: path: ../../src/Controller/OAuth/ namespace: App\Controller\OAuth type: attribute kernel: resource: ../../src/Kernel.php type: attribute