Created
February 28, 2011 06:54
-
-
Save mythz/847021 to your computer and use it in GitHub Desktop.
Install Nginx 0.9.5 on OSX
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
## DOWNLOADS | |
sudo curl -OL h ftp://ftp.csx.cam.ac.uk/pub/software/programming/pcre/pcre-8.12.tar.gz > /usr/local/src/pcre-8.12.tar.gz | |
sudo curl -OL h http://nginx.org/download/nginx-0.9.5.tar.gz > /usr/local/src/nginx-0.9.5.tar.gz | |
## Install PCRE | |
sudo mkdir -p /usr/local/src | |
cd /usr/local/src | |
tar xvzf pcre-8.12.tar.gz | |
#not needed when nginx configured to build pcre statically | |
#cd pcre-8.12 | |
#./configure --prefix=/usr/local | |
#make | |
#sudo make install | |
#cd .. | |
## Install Nginx | |
sudo tar xvzf nginx-0.9.5.tar.gz | |
cd nginx-0.9.5 | |
./configure --prefix=/usr/local --with-http_ssl_module --with-pcre=/usr/local/src/pcre-8.12 | |
make | |
sudo make install | |
## Start Nginx | |
echo installation complete, ensure /usr/local/sbin is added to your $PATH | |
echo starting nginx on http://localhost/ | |
sudo /usr/local/sbin/nginx |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment