Created
June 13, 2017 19:34
-
-
Save luisfc/daabb72b56956f3abfcacbeb80dcb301 to your computer and use it in GitHub Desktop.
Install phpMyAdmin Ubuntu 16.04 and php7-fpm
This file contains hidden or 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
sudo apt update | |
sudo apt install phpmyadmin | |
This is a : no need to think setup for Ubuntu 16.04 with php7-fpm already installed. | |
Then copy paste just before the last } of the file the following block into /etc/nginx/sites-avaliable/default | |
location /phpmyadmin { | |
root /usr/share/; | |
index index.php index.html index.htm; | |
location ~ ^/phpmyadmin/(.+\.php)$ { | |
try_files $uri =404; | |
fastcgi_pass unix:/var/run/php/php7.0-fpm.sock; | |
include fastcgi_params; | |
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; | |
} | |
location ~* ^/phpmyadmin/(.+\.(jpg|jpeg|gif|css|png|js|ico|html|xml|txt))$ { | |
root /usr/share/; | |
} | |
} | |
Save and restart nginx with : | |
sudo service nginx restart |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment