You are here

Burris LEMPA Stack Overview

AWS Linux

During setup, the Burris Builder script converts a "vanilla" (read: flavored for the cloud, but still generic) Amazon Linux distribution into web server optimized for website delivery. For the Linux inclined, Amazon Linux appears to a hybrid of CentOS and Fedora. If you are searching for OS level help or documentation, most information which applies to these distributions will apply to Amazon Linux as well.

Nginx

Nginx powers the web server for Burris Builder. It is decoupled from the PHP service, provided by PHP-FPM, which compared to the "traditional" Apache method of delivering a website, creates both advantages and challenges. A separated PHP processor allows better scalability (it may be moved to its own server or even its own cluster if necessary), more flexibility for creating environments on the same server such as pools. It allows more granularity for treatment of different traffic types such as images, css or js. The tradional PHP module method of delivering a page means a PHP library is spawned for every request, regardless if the request is for an image asset or a PHP page.

Burris Builder Usage

When you create a website, very little is actually written to the config file. Instead, a series of config files are included according to the website you type you choose. These files are located on the server in the /etc/nginx/apps folder. Drupal, WordPress and Custom website types include files for Drupal, WordPress and Git/Blank website respectively.

MySQL

MySQL is installed as a support database for Burris Builder. However, it is recommended to run websites using a separate, RDS server for maximum performance and flexibility.

The root password for your local MySQL installation is contained in the User Data file when launching the server, using the "-m" switch. There are no special configurations made to the locatl installation. The local databases may be accessed through MySQL cli or the PhpMyAdmin utility, covered in the Utilities section of the documentation.

PHP-FPM

PHP-FPM is the service which parses PHP code for your websites, and it runs as a separate service from Nginx. Upon creating a Burris Builder web server, a Burris Builder github repo is loaded into the PHP-FPM configuration directory. This set of configuration files, www-dev.conf, www-stage.conf and www.conf contain pools for development, staging and live pools respectively. The primary differences are the levels of error display, memory used and worker spawning. The files referenced here are located in the /etc/php-fpm.d directory.

Development Pool: www-dev.conf

This pool is expected to receive very little traffic and report all errors to the screen.

Worker spawning is set "ondemand" which means workers are created only as needed. The number of wokers max out at 2. Additionally, since this pool is expected to work with experimental code,

Staging Pool: www-stage.conf

The staging pool is a hybrid of development and live, caching gets more aggressive but errors are still verbose and printed to screen. The stage directories are not blacklisted from cache, nginx configs are slightly more aggressive with caching, and there is a slight increase in maxmimum workers.

Live Pool: www.conf

The live pool allows the most amount of workers, offers the most agressive caching, and reports errors only to the logs.

If you make any changes to PHP files which are served by the stage or live pools, you will need to clear OpCache in order to see changes. Cache may cleared by using the sudo service php-fpm reload command in an SSH terminal, or by clicking the reset button in the OpCacheGUI utilitiy

Apache

Apache is used only for WebDav. It's default configuration removes the PHP module to save on memory, and processes all PHP files as text in order to deliver them to WebDav unprocssed.

The number of workers for Apache is expected to be low, and runs as a BurrisX user in order to have permission writing to web directories.

Since WebDav is run on HTTP protocol, the connection may be tested inside any web browser. Simply open the WebDav addresses listed in the Burris Builder Admin in any web browser, and type in your username and password when prompted. While you cannot write from your browers, you will be able to browser your file directory and view your PHP files as text files.