Reputation: 6062
Cross-posted from the official Symfony Google Group because time is an issue:
I'm in the final push to upload my site to my host. Everything runs fine in the dev environment - no errors, no warnings. When I attempt to access it in prod (localhost/web/app.php/), I get a blank screen. I attempted to clear the cache, to see if that would help, but got the following error:
$ app/console cache:clear --env=prod
[Symfony\Component\DependencyInjection\Exception\InvalidArgumentException]
The parameter "kernel.trusted_proxies" must be defined.
I can clear the dev cache without issue.
Please help.
Upvotes: 5
Views: 3887
Reputation: 2452
You'll need to add trusted_proxies to your config, even if it is blank.
Within: app/config/config.yml
add:
framework:
trusted_proxies: ~
You'll also likely want to delete your cache files (app/cache/prod
) and then run your console cache clear ($ app/console cache:clear --env=prod
)
Upvotes: 16