Skip to content
Merged
Show file tree
Hide file tree
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
2 changes: 1 addition & 1 deletion caddy/frankenphp/Caddyfile
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
# }
#}

root public/
root {$SERVER_ROOT:public/}
encode zstd br gzip

# Uncomment the following lines to enable Mercure and Vulcain modules
Expand Down
1 change: 1 addition & 0 deletions docs/config.md
Original file line number Diff line number Diff line change
Expand Up @@ -236,6 +236,7 @@ You can find more information about this setting in the [Caddy documentation](ht
The following environment variables can be used to inject Caddy directives in the `Caddyfile` without modifying it:

- `SERVER_NAME`: change [the addresses on which to listen](https://caddyserver.com/docs/caddyfile/concepts#addresses), the provided hostnames will also be used for the generated TLS certificate
- `SERVER_ROOT`: change the root directory of the site, defaults to `public/`
- `CADDY_GLOBAL_OPTIONS`: inject [global options](https://caddyserver.com/docs/caddyfile/options)
- `FRANKENPHP_CONFIG`: inject config under the `frankenphp` directive

Expand Down
1 change: 1 addition & 0 deletions docs/fr/config.md
Original file line number Diff line number Diff line change
Expand Up @@ -235,6 +235,7 @@ Vous trouverez plus d'informations sur ce paramètre dans la [documentation Cadd
Les variables d'environnement suivantes peuvent être utilisées pour insérer des directives Caddy dans le `Caddyfile` sans le modifier :

- `SERVER_NAME` : change [les adresses sur lesquelles écouter](https://caddyserver.com/docs/caddyfile/concepts#addresses), les noms d'hôte fournis seront également utilisés pour le certificat TLS généré
- `SERVER_ROOT` : change le répertoire racine du site, par défaut `public/`
- `CADDY_GLOBAL_OPTIONS` : injecte [des options globales](https://caddyserver.com/docs/caddyfile/options)
- `FRANKENPHP_CONFIG` : insère la configuration sous la directive `frankenphp`

Expand Down
3 changes: 3 additions & 0 deletions docs/fr/production.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,9 @@ ENV SERVER_NAME=your-domain-name.example.com
# Si vous souhaitez désactiver HTTPS, utilisez cette valeur à la place :
#ENV SERVER_NAME=:80

# Si votre projet n'utilise pas le répertoire "public" comme racine web, vous pouvez le définir ici :
# ENV SERVER_ROOT=web/

# Activer les paramètres de production de PHP
RUN mv "$PHP_INI_DIR/php.ini-production" "$PHP_INI_DIR/php.ini"

Expand Down
3 changes: 3 additions & 0 deletions docs/production.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,9 @@ ENV SERVER_NAME=your-domain-name.example.com
# If you want to disable HTTPS, use this value instead:
#ENV SERVER_NAME=:80

# If your project is not using the "public" directory as the web root, you can set it here:
# ENV SERVER_ROOT=web/

# Enable PHP production settings
RUN mv "$PHP_INI_DIR/php.ini-production" "$PHP_INI_DIR/php.ini"

Expand Down
Loading