Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- add nginx repository:
- sudo apt-get install python-software-properties
- sudo add-apt-repository ppa:nginx/stable
- update database:
- sudo apt-get update
- install nginx:
- sudo apt-get install nginx
- restart nginx:
- sudo /etc/init.d/nginx start
- install php(php5-fpm):
- sudo apt-get install php5-cli php5-cgi php5-fpm php5-mcrypt
- edit nginx config file:
- sudo nano /etc/nginx/sites-available/default
- The changes you will need to make are as follows:
- 1) index index.html index.htm;
- to
- index index.html index.htm index.php;
- uncomment the following lines:
- location ~ \.php$ {
- fastcgi_pass unix:/var/run/php5-fpm.sock;
- fastcgi_index index.php;
- include fastcgi_params;
- }
- restart nginx and php5-fpm:
- sudo /etc/init.d/nginx restart
- sudo /etc/init.d/php5-fpm
- install mysql:
- sudo apt-get install mysql-server mysql-client php5-mysql
- install phpmyadmin(if ask what type of webserver-apache or lighthttpd- don't pick any and continue. if ask about dbconfig answer no):
- sudo apt-get install phpmyadmin
- link phpmyadmin to nginx default path:
- ln -sf /usr/share/phpmyadmin /usr/share/nginx/html
- restart nginx:
- /etc/init.d/nginx restart
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement