Question

installing phpmyadmin to nginx centos server

There isnt any tutorial about installing phpmyadmin to nginx on centos server. I googled it and I found here http://www.tecmint.com/install-phpmyadmin-for-apache-or-nginx-on-rhelcentos-6-3-5-8-fedora-17-12/ .

The problem is there isnt any directory called “etc/nginx/sites-available” in my server.

Can someone make a tutorial for that please? I really need phpmyadmin.

Show comments

Submit an answer

This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Want to learn more? Join the DigitalOcean Community!

Join our DigitalOcean community of over a million developers for free! Get help and share knowledge in Q&A, subscribe to topics of interest, and get courses and tools that will help you grow as a developer and scale your project or business.

First, to get a LEMP stack on CentOS up and running, follow this article:

https://www.digitalocean.com/community/tutorials/how-to-install-linux-nginx-mysql-php-lemp-stack-on-centos-6

Then install phpmyadmin with: <pre> sudo yum --enablerepo=remi install phpmyadmin </pre> Then edit <code>/etc/nginx/conf.d/default.conf</code> to include: <pre> location /phpmyadmin { alias /usr/share/phpMyAdmin/; } </pre> Then finally, restart php and nginx: <pre> service nginx restart service php-fpm restart </pre> Now, it will be available at http://your.ip.address/phpmyadmin

You can find your sites-avaiable directory in <code>nginx.conf</code> file. TIP: You can setup specifc por on server to respond for phpMyAdmin. Virtualhosts are awesome, take a look at <a href=“http://wiki.nginx.org/ServerBlockExample”>http://wiki.nginx.org/ServerBlockExample</a>