In this guide I want to show how to install Nginx server on Mac OS X.
Installation steps:
Now open your browser and goto http://localhost. If you see Nginx welcome page.
Detailed information about server configuration can be found here: http://nginx.org/
Prerequisites
- In order to be able to compile source code you will need Xcode with Command Line Tools installed. If you already have Xcode installed check if Command Line Tools installed: Xcode -> Preferences -> Download.
- Nginx requires PCRE (Perl Compatible Regular Expressions). We only need source code, because we'll be doing static compilation in this guide. The source can be downloaded here: ftp://ftp.csx.cam.ac.uk/pub/software/programming/pcre/
- Nginx sources can be downloaded here: http://nginx.org/en/download.html
Installation
Installation steps:
- Extract PCRE and Nginx archives in temp folder. You wil have 2 folders, e.g.: prce-8.33 and nginx-1.4.2
- Go to nginx-1.4.2 and run following commands:
$ ./configure --prefix=/usr/local/nginx --with-http_ssl_module --with-pcre=../pcre-8.33 $ make $ sudo make install
- After those commands Nginx will be installed into /usr/local/nginx
To start Nginx run the following command:
$ /usr/local/nginx/sbin/nginx
Now open your browser and goto http://localhost. If you see Nginx welcome page.
Detailed information about server configuration can be found here: http://nginx.org/
No comments:
Post a Comment