I’m very proud to announce the immediate availability of FrankenPHP 1.0 beta.
FrankenPHP is a brand-new application server for PHP, written in Go and built on top of Caddy, that dramatically simplifies the deployment of PHP apps, and brings new features to PHP such as:
- a worker mode that improves typical application performance by a factor of 3
- native support for HTTP/3
- native support for the 103 Early Hints HTTP status code (assets preloading)
- automatic HTTPS certificate generation and renewal
- native support for the Mercure protocol (real-time data broadcasting)
- and much more!
FrankenPHP is available as a Docker image (Debian, Alpine, PHP 8.2, and PHP 8.3 variants are available) and as standalone binaries with 0 dependencies for Linux and macOS.
Here is the slideshow I used during the opening keynote of the API Platform Conference to introduce FrankenPHP and API Platform 3.2, which now includes FrankenPHP:
What’s to point of sticking to PHP, why not just write everything in go for go ?
> What’s to point of sticking to PHP
PHP is a very expressive language. There are things you can do in PHP that is hard to do in other languages (i.e., reflection) and it isn’t terribly slow. As someone who used to write in C# and PHP a lot, there are patterns in PHP that are too complex to implement in C# but only a few lines of code in PHP.
Further, PHP has all the bits needed for web-dev, built-in. It also has some fantastic frameworks for building stuff really fast. If you like Slack, or Facebook, or many other popular products, they all initially started as PHP.
Can you elaborate what are the “patterns in PHP that are too complex to implement in C#” please?
To run WordPress ofc
This looks awesome… Thanks for the great work here.
Does this support WordPress?
Yes it does. Checkout the GitHub page. There is a sample of WordPress.
Seems like, https://github.com/dunglas/frankenphp-wordpress
Is php faster than python ?
Yes, and by a lot.
This looks awesome! Alas, following the docker instructions
docker run -v $PWD:/app/public -p 80:80 -p 443:443 dunglas/frankenphp
Gives a privacy error, can’t connect.
I saw the message about certutil, but libnss3-tools is already installed (and worked fine with the Symfony CLI).
{“level”:”info”,”ts”:1695385935.8757255,”logger”:”tls”,”msg”:”cleaning storage unit”,”description”:”FileStorage:/data/caddy”}
{“level”:”info”,”ts”:1695385935.8757498,”logger”:”tls”,”msg”:”finished cleaning storage units”}
{“level”:”warn”,”ts”:1695385935.8852496,”logger”:”pki.ca.local”,”msg”:”installing root certificate (you might be prompted for password)”,”path”:”storage:pki/authorities/local/root.crt”}
{“level”:”info”,”ts”:1695385935.8854089,”msg”:”warning: \”certutil\” is not available, install \”certutil\” with \”apt install libnss3-tools\” or \”yum install nss-tools\” and try again”}
{“level”:”info”,”ts”:1695385935.8854134,”msg”:”define JAVA_HOME environment variable to use the Java trust”}
{“level”:”info”,”ts”:1695385936.2782574,”msg”:”certificate installed properly in linux trusts”}
{“level”:”info”,”ts”:1695385936.2783787,”logger”:”http”,”msg”:”enabling HTTP/3 listener”,”addr”:”:443″}
{“level”:”info”,”ts”:1695385936.2784247,”msg”:”failed to sufficiently increase receive buffer size (was: 208 kiB, wanted: 2048 kiB, got: 416 kiB). See https://github.com/quic-go/quic-go/wiki/UDP-Buffer-Sizes for details.”}