Skip to content

Instantly share code, notes, and snippets.

@mrcolts
Forked from tsolar/phpmyadmin
Created July 27, 2020 08:29
Show Gist options
  • Save mrcolts/2f767c4c12126483496289331afaa8ae to your computer and use it in GitHub Desktop.
Save mrcolts/2f767c4c12126483496289331afaa8ae to your computer and use it in GitHub Desktop.
phpmyadmin nginx config
server {
location /phpmyadmin {
root /usr/share/;
index index.php index.html index.htm;
location ~ ^/phpmyadmin/(.+\.php)$ {
try_files $uri =404;
root /usr/share/;
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
include /etc/nginx/fastcgi_params;
}
location ~* ^/phpmyadmin/(.+\.(jpg|jpeg|gif|css|png|js|ico|html|xml|txt))$ {
root /usr/share/;
}
}
location /phpMyAdmin {
rewrite ^/* /phpmyadmin last;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment