Where is the web environment installed?

Hi guys, just curious, I’m not super experienced in this but I was wondering where is the web stack installed? For example, does LocalWP simply uses the MySQL already installed in my machine? In case I hadn’t installed, would LocalWP install it for me? The same for nginx, for example. After installation of LocalWP, I would expect to see something for example when I run “nginx -v” on the terminal, but I only get that the command does not exist. I’m guessing it’s just because it’s a local (no pun) installation from LocalWP, but, where is it? I’m on a Mac by the way.

Thanks guys!

Hi @cucu!

You’re on the right track! Everything is Local and contained within the app. So when you get a site going that kicks on the database engine, and when you close your site/Local down everything is saved and stopped.

Another user had some similar questions over here and so this thread might help provide some clarity as well: Location of database files and software - #7 by silverblatt

Thank you Nick! That was helpful indeed!

If you allow me, it seems that each site will have it’s own app and conf directories, each with their own instance of mysql, nginx and php, correct? Does that mean, and would it be correct to say, that each site is kind of “containerized”? Not sure if in a docker fashion if you will, but it seems different than a solution like Xampp, in which it seems to mimic a dev environment in a different way. If not containerized, what kind of setup would this be?

Thanks for your help!

Hi @cucu

If you allow me, it seems that each site will have it’s own app and conf directories, each with their own instance of mysql, nginx and php, correct?

That is correct!

Does that mean, and would it be correct to say, that each site is kind of “containerized”?

In a sense, yes.

Not sure if in a docker fashion if you will, but it seems different than a solution like Xampp, in which it seems to mimic a dev environment in a different way. If not containerized, what kind of setup would this be?

I’m not familiar with the setups for Docker or Xampp to be able to compare. I’m sure our Devs could expand on this a bit further.

Are these questions based solely on curiosity or is there some sort of troubleshooting or technical limitation that you’re concerned about?

Thanks @Nick-B, at the moment curiosity indeed. I’m not sure if I can ask your devs to expand on this? Or even if there are more detailed docs about this matter?

Thanks again!

Hi @cucu you can always look through our help docs here: Archives: Help Docs - Local

As far as one single document that explains the ins and outs of how the application is built and works we don’t have anything like that to point you towards. If you have more specific questions about things behind the scenes I can share your post with the dev team next week.

Thanks for that @Nick-B , that would be great! There’s no big rush on this as I’m sure your devs are super busy, but that would be amazing! Thanks again and I’ll have a look at the docs as well.

Thanks so much again

Hi @cucu - the web stack is bundled with Local. Local has default binaries for PHP, DB, and the web server that come with the app when you install. If a user wants a different version of PHP, for example, this service gets downloaded and stored in Local’s application directory. Local will not reference the packages already installed on the user’s machine.

Each site has its own “instance” of MySQL, nginix, and PHP, though the binaries that power them are shared. The sites rely on the same binary and then can be customized based on the config files for each site individually.

The binaries that come bundled with Local are located at Applications/Local/Contents/Resources/extraResources - you can dive into the lightning-services folder to see more from there.

The binaries that Local downloads (if a user chooses a version of PHP that isn’t bundled with Local, for example) are at ~/Library/Application Support/Local/lightning-services.

Hopefully that answers your questions!

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.