This certainly falls under the "more interesting than practical" of things I've done.
Since I've recently aquired a few Raspberry Pi Zero's, I've been playing around with running Nginx and PHP on them, and experimenting with a functional web server on the Raspbian platform. Somewhere along the way I built all packages I actively maintain for Raspbian Jessie.
For those interested (and crazy enough) to run a full Nginx/PHP stack on a Raspberry Pi Zero, the following script can be used to get you started.
Add the debian repository
sudo sh -c 'echo "deb https://deb.erianna.com jessie raspbian" > /etc/apt/sources.list.d/deb.erianna.com.list'
Install secure https transport for apt
sudo apt-get install apt-transport-https
Upgrade gnupg2 to 2.1.x for ECC key support (for gpg package verification)
sudo apt-get --allow-unauthenticated update sudo apt-get --allow-unauthenticated install gnupg2 -y
sudo ln -s /etc/ld.so.conf.d/gpg2.conf /etc/ld.so.conf.d/000-gpg2.conf sudo ldconfig
Download GPG Signing Key from Keybase
wget --quiet -O - https://keybase.io/charlesportwood/key.asc | sudo apt-key add -
Update to verify packages can be downloaded and authenticated
sudo apt-get update
Install Nginx, and PHP
sudo apt-get install nginx-mainline php7.0-fpm ```
Note these instructions are identitical to my main repository, and are packages using the same scripts used to provide them. Nginx is compiled without Google PageSpeed. Both Nginx and PHP are compiled against the latest version of OpenSSL (1.0.2h) without
uint128support. Raspbian is slow on a Pi Zero. Consequently tasks such as generateing dhparams will take a long time. Be patient.