Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 10 additions & 1 deletion laravel/advanced-guides/using-symfony.html.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,10 @@ To accomplish this, we'll create a custom `SymfonyRuntime` class and use that wh
Create file `.fly/FlySymfonyRuntime.php` with the following contents:

```php
<?php

namespace App;

class FlySymfonyRuntime extends SymfonyRuntime
{
public function __construct(array $options = [])
Expand Down Expand Up @@ -62,7 +66,12 @@ We also need to tell Symfony to use the `FlySymfonyRuntime` by setting an enviro

Symfony needs to be aware of the Fly Proxy in order to generate links correctly (among other things). The Fly proxy is a routing layer (similar to a load balancer) that sits between your application server and the public internet.

The proxy terminates SSL connections, and sends "http" requests to your application. We need to tell Symfony to [trust this proxy](https://symfony.com/doc/current/deployment/proxies.html) by editing file `config/packages/framework.yaml` and adding `trusted_proxies: '127.0.0.1,REMOTE_ADDR'`.
The proxy terminates SSL connections, and sends "http" requests to your application. We need to tell Symfony to [trust this proxy](https://symfony.com/doc/current/deployment/proxies.html) by editing file `config/packages/framework.yaml`:

```yaml
framework:
trusted_proxies: '127.0.0.1,REMOTE_ADDR'
```

## Detail Work

Expand Down