The secret behind FrankenPHP: Will it revolutionize PHP?

แชร์
ฝัง
  • เผยแพร่เมื่อ 31 ธ.ค. 2024

ความคิดเห็น • 173

  • @BenHolmen
    @BenHolmen ปีที่แล้ว +29

    Huh this is a real paradigm shift! I'm eager to see how it is embraced by the community. Thanks Chris!

  • @LukasRotermund
    @LukasRotermund ปีที่แล้ว +17

    Working with Go, I have become very accustomed to this convenient deployment method. I can't wait to do the same in PHP now ❤️ Thanks for the quick overview.

    • @fideloper
      @fideloper  ปีที่แล้ว

      Same, love that especially!

  • @DaviMartins99
    @DaviMartins99 ปีที่แล้ว +5

    This thing is absolutely INSANE.
    Awesome content, Chris!

    • @fideloper
      @fideloper  ปีที่แล้ว +2

      it's really cool, right? Thanks for the kind words!

  • @Protoscribe
    @Protoscribe ปีที่แล้ว +4

    Outside of the scope of the video for a second - @ 02:04 - I literally wet myself laughing. You've got a new subscriber... Onto the scope of the video. I have not PHP'd in over a decade because of Node and Go, except for the odd Laravel project that I would take over, and this certainly makes me want to check out PHP again because when I am not doing some fancy Kubernetes and Edge work, I use Caddy as my go to server because the API is stellar and you can set servers up on the fly with a couple API calls.

    • @fideloper
      @fideloper  ปีที่แล้ว +1

      It turns out everyone *loves* being told to F off!

  • @oszi7058
    @oszi7058 ปีที่แล้ว +57

    I'm at a point where i think performance for 99.9% of apps and sites created is not that important considering the 20 monthly users and a crushed dev dream xD

    • @fideloper
      @fideloper  ปีที่แล้ว +7

      no users no problems!

    • @freemium8092
      @freemium8092 ปีที่แล้ว +7

      Tutorial how to get 20 monthly users pleaseeee

    • @LukeCreates
      @LukeCreates 7 หลายเดือนก่อน

      Used to work on pretty low RPS projects… until I didn’t. And now I couldn’t be more thankful that these servers exist.

  • @ViniciusBecker01
    @ViniciusBecker01 ปีที่แล้ว +2

    Wow, that's crazy... Thank you, Chris! Will try it soon!

  • @akunbeben
    @akunbeben ปีที่แล้ว +1

    I've watched this video 4 times today, I love it!

    • @fideloper
      @fideloper  ปีที่แล้ว

      sorry for flipping you off so much

  • @travisthomson1637
    @travisthomson1637 ปีที่แล้ว +1

    Thank you for bringing me up to speed on this. Was wondering what it was!

    • @fideloper
      @fideloper  ปีที่แล้ว

      you’re welcome!

  • @spamman888
    @spamman888 ปีที่แล้ว +4

    How does it handle things like the storage directory? Should you just assume that you'll need to plug it into an s3 driver?

    • @giandomenicodisalvatore7187
      @giandomenicodisalvatore7187 ปีที่แล้ว

      I was thinking about it too, maybe it behaves just like vanilla php? 🤔

    • @fideloper
      @fideloper  ปีที่แล้ว

      Great question - I’m pretty sure you’ll need to define a directory on your file system but is NOT in the code base storage directory (or, use s3!)

    • @Ruhigengeist
      @Ruhigengeist ปีที่แล้ว +3

      When running from embedded mode, it unpacks to a /tmp dir at startup, so storage will work as normal by default. But it does mean uploaded files would be lost on redeploy because it would use a new temp dir. Make sure to change the storage dir to somewhere else on the system so it stays persisted across deploys. Or yeah, use S3 if that's an option for you.

    • @labkitadev
      @labkitadev ปีที่แล้ว

      @@Ruhigengeistfor storage i think use minio is the best option if you use docker

  • @jit-r5b
    @jit-r5b 11 หลายเดือนก่อน +3

    Your last chapter reminded me of people, and perhaps me the most, spending hours upon winning two milliseconds in context of nginx vs caddy, when a relationship query is taking 500ms 🤣🤣

    • @tomasprochazka6198
      @tomasprochazka6198 10 หลายเดือนก่อน +1

      Don't forget the folks who always struggle with the auto-cert with Nginx.

  • @giandomenicodisalvatore7187
    @giandomenicodisalvatore7187 ปีที่แล้ว +13

    Frankenphp approach is very promising (and I ❤ 103 early hints).
    I would like to hear your thoughts about its mercure-based realtime module and laravel queues/jobs implementation using frankenphp
    Thank you for your Outstanding content! 🏆

    • @fideloper
      @fideloper  ปีที่แล้ว +3

      thanks!! I haven’t used mercure yet but I’m excited to try it out as well

  • @jozsab1
    @jozsab1 ปีที่แล้ว +9

    never had deployment issues for PHP. at least I learned some people struggle with this. Nice to know there is a complicated method that encapsulates the previously existing "complicated" method.

    • @TheHronar
      @TheHronar 2 หลายเดือนก่อน

      I don't have deployment issues either however I do think that this will make a lot of lives easier for the non dev-ops peeps.
      It encapsulates everything you need at the version you need it in a single file. All you need is a base OS and nothing more. This takes away a lot of the "Well, It works on my machine" issues since presumably it will be built with the same dependancies that were used during development.

  • @JayTheKing111
    @JayTheKing111 ปีที่แล้ว +3

    It's worth noting that your connection is still private regardless of the warning from the browser. The reason the browser complains is because it can't resolve the root CA for which signed the certificate since its self signed locally.

  • @underflowexception
    @underflowexception 10 หลายเดือนก่อน +1

    How would the Laravel task scheduler be setup ? Will it leverage the existing
    binary or will you need to install PHP on the host machine and setup a cronjob?

    • @fideloper
      @fideloper  9 หลายเดือนก่อน

      you can use the existing binary to run any command

  • @seeds_of_growth-yi5gx
    @seeds_of_growth-yi5gx 11 หลายเดือนก่อน

    I think putting it architecturally side by side with nginx + fpm could provide clarity, thanks for sharing, cheers!

  •  ปีที่แล้ว +1

    Really interesting, thanks for the overview. I'm excited to try this soon!

    • @fideloper
      @fideloper  ปีที่แล้ว

      thanks? I really like it so far, I need to play with it to feel out its rough edges (if any)

  • @mohamed-haj
    @mohamed-haj ปีที่แล้ว +1

    Great episode as always!

    • @fideloper
      @fideloper  ปีที่แล้ว

      thank you, really appreciate it!

  • @paulobitfranca
    @paulobitfranca 9 หลายเดือนก่อน +1

    Hi. I'm trying to run the frankphp in a different port. Is it possible to specify a port different from default (80) on run it?
    Thanks

    • @fideloper
      @fideloper  9 หลายเดือนก่อน

      unsure! did you figure that out? (in their docs?)

    • @paulobitfranca
      @paulobitfranca 9 หลายเดือนก่อน

      @@fideloper I didn't find anything. I forgot to mention... I'm talking about the standalone binary, not about the docker version

  • @razvangrigore322
    @razvangrigore322 10 หลายเดือนก่อน +2

    Crazy. I was just about to use Nginx Unit with PHP inside one container and now I see this.

    • @fideloper
      @fideloper  10 หลายเดือนก่อน +1

      it’s worth experimenting to see which you like better! Since Franken uses caddy, i think you get more configuration (it’s a full web server, i think Unit has less features)

  • @tmanley1985
    @tmanley1985 ปีที่แล้ว

    I can't decide if I love this or really love this.

    • @fideloper
      @fideloper  ปีที่แล้ว

      we love to love

  • @DanielAbernathy
    @DanielAbernathy ปีที่แล้ว +1

    I'd be curious to learn what steps are required to secure a web server when you're running the standalone executable. Any different than a typical PHP deployment?

    • @fideloper
      @fideloper  ปีที่แล้ว +1

      Yeah, I don’t think there’s anything too magical there - same stuff as usual! In theory you can edit the Caddyfile config for things like blocking access to dotfiles

  • @Z4KIUS
    @Z4KIUS ปีที่แล้ว

    I love the contained executable, it can be useful when making things for less technical people, you can't expect them to install docker or PHP on metal

    • @fideloper
      @fideloper  ปีที่แล้ว

      yeah, good point

    • @MaulikParmar210
      @MaulikParmar210 ปีที่แล้ว

      The project comes with build system, caddy has it, there can be single binary for entire php app. It's just not popular option and has a bit of learning curve on how caddy build and modules works.
      People prefer php with more of fpm approach abd are used to it. The project aims towards having full fledged application server which has alot more responsibilities than a typical sertup.

  • @sean_reyes
    @sean_reyes 4 หลายเดือนก่อน

    Storage? Where will it store uploaded files?

  • @WarshipSub
    @WarshipSub 4 หลายเดือนก่อน

    PHP does not need revolutionize. PHP is life as it is.

  • @RoniStudio
    @RoniStudio 22 วันที่ผ่านมา

    Did they move everything on memory while in runtime, so every execution no need to check on storage anymore.

    • @fideloper
      @fideloper  10 วันที่ผ่านมา

      that’s worker mode (with laravel it’s Octane). There’s “regular” mode too which reads the php code on every request similar to FPM. (which is all separate from php’s opcache which can also be used)

  • @kruhlyk_ua
    @kruhlyk_ua 4 หลายเดือนก่อน

    Thanks for video! Could you make some performance tests? How much FrankenPHP is strong for huge loading?

  • @JupiterBarrera
    @JupiterBarrera ปีที่แล้ว +1

    Awesome stuff, I'll check it out

    • @fideloper
      @fideloper  ปีที่แล้ว

      def am curious to try it in prod myself and to see how it goes!

  • @seeds_of_growth-yi5gx
    @seeds_of_growth-yi5gx 11 หลายเดือนก่อน

    how does it compare with preloading, JIT...etc ?

  • @JohnnyBigodes
    @JohnnyBigodes ปีที่แล้ว

    I am used to deploy my built images and use these as multi purpose containers for the Scheduler and or Queue. Does this also work here?

    • @fideloper
      @fideloper  ปีที่แล้ว +1

      yep, essentially the same concept! You use the same binary to run the web server or commands line “artisan queue:listen”

    • @JohnnyBigodes
      @JohnnyBigodes ปีที่แล้ว

      @@fideloper Nice... Thank you for the answer

  • @patricknelson
    @patricknelson ปีที่แล้ว

    6:08 - I don’t copy .env files at all into docker images. At minimum probably best to inject into actual environment variables and reference somehow via getenv() (that’s just low level, your particular framework may vary), especially if they contain any secrets. This just avoids them sitting around in container images. In deployed environments, those env vars are injected via some other means (e.g. in Kubernetes via secrets or via secret manager in GCP, etc).
    In your local dev or insecure test environments, you can easily stub out those env vars via env_file in docker-compose for example.

    • @fideloper
      @fideloper  ปีที่แล้ว

      Agree, that's how Fly.io works too (where I work) - the .env file is actually removed (by default, you can add it in if you really want it) when creating a Docker image (technically a full VM image) to deploy.

  • @smtkumar007
    @smtkumar007 11 หลายเดือนก่อน +1

    i wanted to ship a mysql server as well , does it bundle that as well?

    • @fideloper
      @fideloper  11 หลายเดือนก่อน

      this isn’t a whole server, nope! Think is this as just rubbing your app code, no database or anything else

  • @robertcoster5644
    @robertcoster5644 ปีที่แล้ว +2

    Interesting. Like to see what the cybersecurity guys make of it before I'd use in production.

  • @nanozone3706
    @nanozone3706 12 วันที่ผ่านมา

    this is gold

  • @seeds_of_growth-yi5gx
    @seeds_of_growth-yi5gx 11 หลายเดือนก่อน

    how do u deal with pecl extensions? that are not listed in the bash file ?

    • @tomasprochazka6198
      @tomasprochazka6198 10 หลายเดือนก่อน

      You can set up the mentioned envs. With it, you can specify a minimal list of your extensions. Notice, that they use static-php-cli to build the static PHP. FrankenPHP, as its name suggests, is just tailored of various components.

  • @patricknelson
    @patricknelson ปีที่แล้ว

    11:36 - re: Are you referring to the good ole’ Nginx + PHP-FPM combination?

    • @fideloper
      @fideloper  ปีที่แล้ว

      comparing caddy vs nginx there, but with PHP apps, FPM of course matters since it's Yet Another Thing™ running. I guess in this case FPM is more comparable to the Franken SAPI (which the Franken Caddy module sends requests to. If I understand it correctly 😂).

  • @hookenz
    @hookenz หลายเดือนก่อน

    The problem with nginx is you have to use it with php-fpm which because of that interface is actually slower than FrankenPHP. However, Nginx released something called "Nginx Unit" which can run PHP natively with one binary just like FrankenPHP. Nginx Unit is not Nginx. It's a completely different codebase to what we all know as Nginx. You should have a look. I think it's good. Performance is much better than nginx + php fpm but also, it has it's downsides.

  • @CaimAstraea
    @CaimAstraea 11 หลายเดือนก่อน

    What about logging and other stuff when you build the binary ?

    • @fideloper
      @fideloper  11 หลายเดือนก่อน +2

      they get spit out through the processes stdout, which you can direct to a file or ship to whatever logging mechanism you want (this is standard for non-php things, php was always the weirdo for really only having a file-based option)

  • @santiagoale6232
    @santiagoale6232 ปีที่แล้ว

    I love this! Gonna follow this expecting the Octane support

    • @Ruhigengeist
      @Ruhigengeist ปีที่แล้ว +1

      Octane support is already out!

    • @santiagoale6232
      @santiagoale6232 ปีที่แล้ว

      @@Ruhigengeist Yep! saw it on LinkedIn the moment it was posted 😍

    • @fideloper
      @fideloper  ปีที่แล้ว +1

      gotta try octane out still myself 🤣, excited for it!

  • @cowgod77
    @cowgod77 ปีที่แล้ว +3

    Sounds interesting. My main question is, if you're already using Docker to package your app, what's the benefit of packaging it into a binary? Your docker image is still going to be prepackaged and ready to run, even if you've just built it traditionally using php-fpm and a dockerfile that installs composer prerequisites etc. If you are already packaging your app in a container for deployment, what would be the advantage of switching to this?

    • @Ffaarg7
      @Ffaarg7 ปีที่แล้ว +1

      Static images seem to be faster - up to 30% - as we saw with Laravel Herd. So I would probably just use the docker image that contains the static build and not extract it. But you may want a more optimised smaller docker image I.e. a different base images and non of the dev C dependencies. Then you could extract it out and create a new docker image for production.

  • @bruceingalls7964
    @bruceingalls7964 ปีที่แล้ว

    Is this recommended for production? It sounds like FrankenPHP does not support *Virtual Hosts* on a shared host. Another apparent downside, is if your Laravel app has additional services, such as email or cron jobs or queues.
    Does one maintain a database outside the docker image?

    • @fideloper
      @fideloper  ปีที่แล้ว +1

      Lots to unpack there! The basic answer there is: there’s a way to handle all of that.
      If you’re hosting in a server where you need to define virtual hosts, this might not be a thing you need (although still possible either through caddy config you can set - see their docs - or by adding nginx or apache in front of the binary made here.
      Cron and all that can be handled just,
      you can run any artisan command with the binary created. you’d run CRON or something that would call the binary to run the scheduler or whatever.
      You wouldn’t run a database in the same container image as the thr application binary (or container image) generated. It can run elsewhere (on whatever server hosts the app or wherever fine databases are sold).

  • @agustingomez7172
    @agustingomez7172 หลายเดือนก่อน

    so i need caddy too right or it comes with caddy?

    • @fideloper
      @fideloper  หลายเดือนก่อน

      comes with caddy!

  • @PhiloDev
    @PhiloDev ปีที่แล้ว

    This is going to make life so much easier 😄

    • @fideloper
      @fideloper  ปีที่แล้ว

      totally could! trying it out soon in prod to see what rough edges i hit if any

    • @PhiloDev
      @PhiloDev ปีที่แล้ว

      @@fideloper time for PHP on the edge haha. Would be great for Livewire, actually have a project where I needed to launch more instances across the world because of the latency you get with Livewire calls.

  • @lamonteplays
    @lamonteplays ปีที่แล้ว

    how easy is this to use with ssl? manual and automatic systems like letsencrypt?

    • @fideloper
      @fideloper  ปีที่แล้ว

      caddy (via certbot) attempts to setup ssl for you! you can tell it not to if you’d like, but in theory you can configure caddy however you like

  • @nchomey
    @nchomey ปีที่แล้ว

    I think a fairly typical use case is to have nginx in front of various web applications/vhosts. Does frankenphp have any support for this, or just for a single application?

    • @fideloper
      @fideloper  ปีที่แล้ว +1

      It's Caddy in front of it, which is a "real" server, and you can configure it on top of what show in the video. You can also put Nginx in front of all of it if you want.
      How I show building it is more suitable for single apps.

    • @tomasprochazka6198
      @tomasprochazka6198 10 หลายเดือนก่อน

      It's typical for some. But Go can be exposed to the world directly, as it has prod-ready server in stdlib. Caddy uses that, with sane defaults for timeouts etc.
      But in theory, you can wrap the servers with how many reverse proxies you want. But with Caddy you don't have to not worry about exposing it directly.

  • @patricknelson
    @patricknelson ปีที่แล้ว +1

    7:53 - Great use case for multi-stage builds 😅
    Sorry for all the comments,but I was wondering about that when I saw that this resulted in a binary. Like… whole app in a single binary? Sick. Very “go” too, lol. But yeah, do your build in one image, then in the next stage (image) you copy that over from the previous stage and you get a WAY smaller resulting image out of that single Dockerfile.

    • @ejunker
      @ejunker ปีที่แล้ว

      The binary is 168M and includes Caddy, PHP, and your application code. I don't think it would be much smaller than if you just packaged your application as a Docker container using the dunglas/frankenphp base image.

  • @svenst
    @svenst ปีที่แล้ว

    Mhhh… but what I’m not fully getting is, .. what if I have already a reverse proxy running? Eg Traefik or Caddy. Would I have then two reverse proxies?

    • @fideloper
      @fideloper  ปีที่แล้ว

      In this case, yep! Which is fine, it's not rare to have like cloudfront/cloudflare -> load balancer -> [multiple web servers running nginx + php-fpm or whatever]

    • @svenst
      @svenst ปีที่แล้ว

      @@fideloper ok, fair enough. Thx for pointing that out 👍 (I was just confused by having 2x caddy. But seems as if caddy in this scenario is used as a 1to1 replacement for nginx)

  • @johnRivs
    @johnRivs ปีที่แล้ว

    How would things like interacting with the filesystem work here?

    • @fideloper
      @fideloper  ปีที่แล้ว

      see other comments, there’s some great answers to it. short answer : they’re in /tmp or similar. set the app to write elsewhere or use s3!

  • @DanielGamboaStewart
    @DanielGamboaStewart ปีที่แล้ว

    This looks insane… if you have any sort of app that is moderately complex we should test the $&@T out of it and see if it’s faster, concurrent requests and page loads on dinámica content etc etc… would love to see a deep dive on server deployment

  • @abdmaster
    @abdmaster ปีที่แล้ว +2

    Really awesome stuff...
    Btw few questions:
    1. Does env still work?
    2. How file storage works in this binary state, can it read storage files?
    3. Blade view compiled files, where will they be stored?

    • @Ruhigengeist
      @Ruhigengeist ปีที่แล้ว +4

      When you run the app, it unpacks the embedded app to a /tmp directory and it serves the app from there. This means compiled blade templates will live in there by default. If you have uploads or whatever that you need to persist, then you'll need to point that to some other directory otherwise they'll be lost on redeploy.
      Yes env works. I assume you mean .env? You can use `--envfile` when running frankenphp I think (the caddy run command lets you do that, I'm not sure if the frankenphp CLI allows that implicitly as well, but it might). Or you can define the env before running the binary using whatever system methods at your disposal (docker env, or systemd env, whatever).

    • @fideloper
      @fideloper  ปีที่แล้ว +1

      env still works! You’ll need to set storage paths to a “real” path on your server disk drive (or use s3 or similar).
      Blade files get written to a temp
      location still I think!

    • @MaulikParmar210
      @MaulikParmar210 ปีที่แล้ว

      1. Env is passed as is.
      2. It's an application server, you're still using php binary for day to day operations so it can do whatever php can do.
      3. Depends on your config, default package is opinionated and has defailt paths. No need to touch cache files if you're following best practices of framework or package itself.

    • @Ruhigengeist
      @Ruhigengeist ปีที่แล้ว

      @@MaulikParmar210 I think you misunderstood their question. They were asking in context of the PHP app (code files) being embedded in the binary at build time, and what effect that has on code that tries to write to files after the fact (because "the files are in the binary and not on disk so what happens?") And I explained above, the answer is the embedded files are unpacked to /tmp first before running the app.

    • @MaulikParmar210
      @MaulikParmar210 ปีที่แล้ว

      @@Ruhigengeist that's default behaviour, it can be changed as per container config for custom images. Thus depends on your config. Does it make clear what an opinionated way is?

  • @renebakx
    @renebakx ปีที่แล้ว +1

    I'am eager to test the build mode, and then run the packaged app binary in a distroless container as a production environment. Going to be fun to figure out how to run other processes like cronjob triggered artisan commanda in the same container or packaged app.

    • @fideloper
      @fideloper  ปีที่แล้ว

      you might just want to run the container they provide instead of building the binary but both should work!

  • @mihaes7172
    @mihaes7172 11 หลายเดือนก่อน

    How the process / the php app is kept alive or restart if chashes? Thanks

    • @fideloper
      @fideloper  11 หลายเดือนก่อน

      depends how you deploy it but in general it’s setup to handle that

  • @patricknelson
    @patricknelson ปีที่แล้ว +1

    “Worker mode” reminds me _a lot_ of OpenSwoole. This feels potentially more stable and easier to implement though. Wonder how they’d benchmark against each other.

    • @Ruhigengeist
      @Ruhigengeist ปีที่แล้ว

      Correct, it's similar. In fact, Laravel Octane support is merged today so you can use FrankenPHP instead of Swoole today.

    • @ROX2
      @ROX2 ปีที่แล้ว

      ​@@Ruhigengeist realy ? what bi-directional websocket protocol replacement in frankenphp ? swoole has coroutines, bi-derectional websocket and work much faster than another "GO" implementation.

    • @MaulikParmar210
      @MaulikParmar210 ปีที่แล้ว

      ​@ROX2 mercure is set to use other protocols than SSE but it's still esrly days and alot of work has been put into this. Did spoke to kevin when we had this leaking memory problem and it's alot more about stability and production ready fleet rather than getting features out. You'll see it evolving over time. This is tip of the icerberg what the ecosystem can do. More people working on it the merrier it gets.

  • @uttula
    @uttula 8 หลายเดือนก่อน +1

    I remember yhe good old times when it was considered bloated if the executable exceeded a few megabytes in size :) oh how the turntables have been turning ;D

    • @fideloper
      @fideloper  7 หลายเดือนก่อน

      definitely not my favorite part of it. Interestingly golang can pretty easily get large too!

  • @AmitErandole
    @AmitErandole ปีที่แล้ว

    Can we see some benchmark tests on a real world application please? Is it really a 3.5x boost? And what about requests per second?

    • @Ruhigengeist
      @Ruhigengeist ปีที่แล้ว +1

      It's ~4x faster than roadrunner & swoole for just the application startup (i.e. just serving the default Laravel homepage). A real world app will not be any faster because only the startup is being cut down, not the actual userland time (this doesn't make PHP execution faster for example). And it obviously can't speed up DB IO etc which is usually your application's biggest bottleneck.

  • @abdellahb1398
    @abdellahb1398 29 วันที่ผ่านมา

    Good but worker mode is only supported by big and heavier frameworks like laravel and symfony.

  • @tannercampbell
    @tannercampbell ปีที่แล้ว

    great overview!

  • @science_trip
    @science_trip ปีที่แล้ว +1

    so we are stopping to use apache or nginx that they are written with champion in performance languages such as C and C++ and we are using a server written in go? And do you name it as evolution?

    • @fideloper
      @fideloper  ปีที่แล้ว +1

      revolution, not evolution. we’re marching in the streets over here.
      do you hear the people sing, singing the sing of angry men 🎶

    • @Ruhigengeist
      @Ruhigengeist ปีที่แล้ว

      The biggest problem with C is memory safety. The amount of bugs and vulnerabilities that happen in C programs is extremely high. For example, remember heartbleed? With Go, that entire class of problem is impossible. The performance difference for the webserver usecase is pretty small. And Caddy has way more modern features, including TLS cert automation, HTTP/3, modern and secure defaults, etc.

    • @science_trip
      @science_trip ปีที่แล้ว

      @@Ruhigengeist did you ever try to hack any C software? I m curious because e lot of people around are talking about safety without knowing what they say. Do you know also memory leaks happed very easy to all modern technologies that they are advertising us like SPAs with all this moden frameworks that they try to "protect" us from mutation? They all fail because the safe code is not about language, but it's about education!

    • @tomasprochazka6198
      @tomasprochazka6198 10 หลายเดือนก่อน +1

      If you care about the performance that much, maybe don't use PHP. This is about a convenience, while the perf penalty is minimal.

    • @science_trip
      @science_trip 10 หลายเดือนก่อน

      @@tomasprochazka6198 in this case I prefer C# or even C++. PHP is a good choice to build normal web apps. And to tell the truth the most important is the database queries and the infrastructure. milliseconds don't matter. the real problem is on what kind of hardware you are using to host the application. this makes the difference but the most TH-camrs don't know it

  • @AbhinavKulshreshtha
    @AbhinavKulshreshtha 8 หลายเดือนก่อน

    Franken php to bundle backend, and deno (hopefully bun too) to bundle and deploy frontend. Maybe someone can come up with installer script for windows, shipping products is going to be smooth as f in future.

  • @fer-ri
    @fer-ri ปีที่แล้ว

    just found out about it and looks promising 👍

    • @fideloper
      @fideloper  ปีที่แล้ว

      yea, really neat! I hope to ship this to production in my next project.

  • @NFM-nb7dl
    @NFM-nb7dl 2 หลายเดือนก่อน

    pls more content about it

  • @aurawindsurfing
    @aurawindsurfing ปีที่แล้ว +1

    I don’t buy this. I move all complexity to my local machine, need to run docker, compile binary etc only to remove it from production server. Are we saving money on production servers? Whats the point? I understand it possible. I understand its new and cool but is it worth it?

    • @fideloper
      @fideloper  ปีที่แล้ว

      I did say you don’t *need* Docker.
      The ideal is to build it in a CI pipeline and ship the resulting executable to production.

    • @aurawindsurfing
      @aurawindsurfing ปีที่แล้ว

      I missed that. But I still need docker for local dev. Docker is ok just trying to figure it out.

  • @noeldacosta7621
    @noeldacosta7621 4 หลายเดือนก่อน

    I mean, ok. This was a useful intro to what's possible but this definitely doesn't count as a "how-to". I'm also not sure you're right about Caddy being slower than Nginx.

  • @aftabnaveed
    @aftabnaveed ปีที่แล้ว

    That middle finger 😲😲🫨

    • @fideloper
      @fideloper  ปีที่แล้ว

      my favorite accident (who counts like that?!)

  • @InMemoryOfNeo
    @InMemoryOfNeo ปีที่แล้ว

    2:03 no problem buddy

  • @PhillipMwaniki
    @PhillipMwaniki ปีที่แล้ว +1

    It's quite beautiful and stunning. Though, the process itself is tedious and error-prone.

    • @fideloper
      @fideloper  ปีที่แล้ว +1

      It keeps improving tho, so I’m really hopeful!

  • @Mohamed.Shosha.
    @Mohamed.Shosha. 10 หลายเดือนก่อน

    Is it best than swoole ?

    • @FilipePetter
      @FilipePetter 7 หลายเดือนก่อน

      nothing is best or worst... its a very shallow way of thinking...
      you should ask, best for X or Y

  • @axMf3qTI
    @axMf3qTI ปีที่แล้ว

    Okay… so why not just use Go en leave PHP behind? All these steps vs go build.

    • @fideloper
      @fideloper  ปีที่แล้ว +4

      Larave is 🐐 (that's coming from someone who programs in Go, Node, Python, and of course PHP). Feature velocity in Laravel is insane.

  • @dadlord689
    @dadlord689 11 หลายเดือนก่อน

    When I am looking at any web stuff I can't believe that it is a binary code. It is super slow and absolutely religious by it's nature. While it is for the most part just an implementation of a prefab concept with a declarative language + some language that is targeting simple projects (getting problematic later). And overall everything web purposed is very similar to a game engine scope. I would expect true revolution for web with something like web-engine with specific IDE and editor. Game engine is an example of how you have an environment that is ready for all sorts of typical stuff and solutions for them in one place. And you don't have to remake everything if you just want to replace a physical engine or rendering pipeline. In few words: to have an actual architecture and not just bunch of unrelated stuff glued together hoping for the best. But I am quite delusional about web as I don't like browser and websites in the first place.

  • @djanthony6662
    @djanthony6662 ปีที่แล้ว

    Wow

  • @fmkoba
    @fmkoba ปีที่แล้ว

    omg Chris, I think you solved a problem that’s been blocking me for the past few months

    • @fideloper
      @fideloper  ปีที่แล้ว

      I have no idea how but I’m glad I did 😂

  • @Bob-tx7hv
    @Bob-tx7hv 11 หลายเดือนก่อน

    finally even PHP can suffer from a complex zero downtime deployment - thanks to single binaries.

    • @fideloper
      @fideloper  11 หลายเดือนก่อน

      ohhh interesting, what’s the complexity? what’s different from other deployment methods?

  • @MarkConstable
    @MarkConstable ปีที่แล้ว

    "you don't need to run docker"... whew, otherwise it would be DOA for me.

  • @gevurahs
    @gevurahs 11 หลายเดือนก่อน +1

    But I mean. Docker already is something you use to be able to deploy things in an easier way. If I have a dockerized application I can deploy it to any cloud environment like aws, azure etc with docker integration. I don't see the point

  • @john5891
    @john5891 ปีที่แล้ว

    Its like nodejs 😮

    • @fideloper
      @fideloper  ปีที่แล้ว +1

      first of all how dare you 😂

  • @iabhitech
    @iabhitech หลายเดือนก่อน

    We will not be able to fix the bug by just opening the file on linux production server😂😂

    • @fideloper
      @fideloper  หลายเดือนก่อน

      immutable deployments sound great! stable! (basically what we get with containers right now anyway) 😂
      but I hear ya, it’s so nice to ssh and patch a thing

  • @flipperiflop
    @flipperiflop ปีที่แล้ว

    Great video, just wished there was less of those "I'm not sure" moments

    • @fideloper
      @fideloper  ปีที่แล้ว

      When it comes to C code, it's "I'm not sure" all the way down. (To be fair to me, some cases are just in the name of making the video not super long. But I also am *NOT* digging into that thread pooling code 😂).

  • @greendsnow
    @greendsnow ปีที่แล้ว

    I want to learn PHP, but there's so many other useful frameworks like Supabase, Appwrite and Pocketbase, I can't find a reason. Sorry.

    • @fideloper
      @fideloper  ปีที่แล้ว +2

      Do whatever works best for you! I do think a full-stack (backend) framework is worth learning over pure frontend + functions tho - you'll learn a ton of stuff important to a full career.

  • @kirayamato6128
    @kirayamato6128 ปีที่แล้ว

    this server is still amateur. Would like to use on a personal project but in real world I'd still choose apache or nginx

    • @Ruhigengeist
      @Ruhigengeist ปีที่แล้ว

      Caddy is an 8 year old project. It's older than kubernetes. I wouldn't call that "amateur". Lots of very big companies use it in production.

  • @webmaster2600
    @webmaster2600 ปีที่แล้ว

    as long as {} and ; exist in PHP. I'm not going back.

    • @fideloper
      @fideloper  ปีที่แล้ว

      I, too, love Python

  • @Gemorroj2
    @Gemorroj2 ปีที่แล้ว

    like roadrunner. the f*king docker is terrible

    • @fideloper
      @fideloper  ปีที่แล้ว

      😂 that’s how i feel about PHP’s official docker images

  • @InMemoryOfNeo
    @InMemoryOfNeo ปีที่แล้ว

    2:03 no problem buddy