You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
first of all, thank you for the 1.0.0 release of FrankenPHP.
I have made some tests and sucessfully built a standalone applications, but i found no documentations on how to configure the embedded Caddyfile.
I mean, i want to deploy the standalone application as a docker image, but when i set Environment variables, it seems that they are not used at all.
So, the question is how to configure this ?
It seems that this default Caddyfile is used:
{
{$CADDY_GLOBAL_OPTIONS}
frankenphp {
#worker /path/to/your/worker.php
{$FRANKENPHP_CONFIG}
}
# https://caddyserver.com/docs/caddyfile/directives#sorting-algorithm
order mercure after encode
order vulcain after reverse_proxy
order php_server before file_server
order php before file_server
}
{$CADDY_EXTRA_CONFIG}
{$SERVER_NAME:localhost} {
log {
# Redact the authorization query parameter that can be set by Mercure
format filter {
wrap console
fields {
uri query {
replace authorization REDACTED
}
}
}
}
root * public/
encode zstd gzip
# Uncomment the following lines to enable Mercure and Vulcain modules
#mercure {
# # Transport to use (default to Bolt)
# transport_url {$MERCURE_TRANSPORT_URL:bolt:///data/mercure.db}
# # Publisher JWT key
# publisher_jwt {env.MERCURE_PUBLISHER_JWT_KEY} {env.MERCURE_PUBLISHER_JWT_ALG}
# # Subscriber JWT key
# subscriber_jwt {env.MERCURE_SUBSCRIBER_JWT_KEY} {env.MERCURE_SUBSCRIBER_JWT_ALG}
# # Allow anonymous subscribers (double-check that it's what you want)
# anonymous
# # Enable the subscription API (double-check that it's what you want)
# subscriptions
# # Extra directives
# {$MERCURE_EXTRA_DIRECTIVES}
#}
#vulcain
{$CADDY_SERVER_EXTRA_DIRECTIVES}
php_server
}
Starting the application with this should set the Caddy server name, but it is not working.
SERVER_NAME=test.com:80 ./my-app php-server
(i saw that there was a "./my-app php-server --domain localhost" in the documentation, but would like to understand how to set other things)
Thank you for your help
The text was updated successfully, but these errors were encountered:
Currently, embedding Caddyfile isn't supported and you're limited to the options available through the command line.
However, adding support for Caddyfile at the root of the app directory should be easy enough. I'll try to work on this soon (PR welcome if someone is quicker).
I tried to run frankenphp standalone with a Caddyfile at the root of my project. I can't make the standalone binary to pick up the Caddyfile for configuration.
Is there a CLI option I need to use? I could not find anything in the docs.
Hello,
first of all, thank you for the 1.0.0 release of FrankenPHP.
I have made some tests and sucessfully built a standalone applications, but i found no documentations on how to configure the embedded Caddyfile.
I mean, i want to deploy the standalone application as a docker image, but when i set Environment variables, it seems that they are not used at all.
So, the question is how to configure this ?
It seems that this default Caddyfile is used:
Starting the application with this should set the Caddy server name, but it is not working.
SERVER_NAME=test.com:80 ./my-app php-server
(i saw that there was a "./my-app php-server --domain localhost" in the documentation, but would like to understand how to set other things)
Thank you for your help
The text was updated successfully, but these errors were encountered: