Files
hydra-sql/misc/files/Caddyfile
vcarroy 9318e753c1
Some checks failed
Cadoles/hydra-sql/pipeline/head There was a failure building this commit
--wip-- [skip ci]
2025-09-26 16:43:39 +02:00

70 lines
1.7 KiB
Caddyfile

# The Caddyfile is an easy way to configure FrankenPHP and the Caddy web server.
#
# https://frankenphp.dev/docs/config
# https://caddyserver.com/docs/caddyfile
{
skip_install_trust
auto_https off
admin off
persist_config off
{$CADDY_GLOBAL_OPTIONS}
frankenphp {
php_ini {
realpath_cache_size 4096K
realpath_cache_ttl 600
opcache.enable_cli 1
opcache.memory_consumption 512
opcache.max_accelerated_files 20000
opcache.preload /app/config/preload.php
opcache.preload_user www-data
apc.enable_cli 1
{$PHPINI_EXTRA_CONFIG}
}
{$FRANKENPHP_CONFIG}
}
}
{$CADDY_EXTRA_CONFIG}
{$SERVER_NAME:localhost} {
root {$SERVER_ROOT:public/}
encode zstd br gzip
{$CADDY_SERVER_EXTRA_DIRECTIVES}
php_server {
root /app/public
try_files {path} index.php
worker {
file /app/public/index.php
env APP_RUNTIME Runtime\FrankenPhpSymfony\Runtime
name hydra-sql-worker
{$FRANKENPHP_WORKER_CONFIG}
}
}
@phpFile {
path *.php*
}
error @phpFile "Not found" 404
@shouldSkip {
expression "{$CADDY_LOG_SKIP:true}" == "true"
path_regexp skipPaths ^/({$CADDY_LOG_FILTER:health|metrics})$
}
skip_log @shouldSkip
log {
output stdout
format {$CADDY_LOG_FORMAT:console}
level {$CADDY_LOG_LEVEL:INFO}
}
}
import Caddyfile.d/*.caddyfile