I've just installed phpMyAdmin on my Nginx server but when I go to https://example.com/phpmyadmin, nothing loads, I only see the main website.
I tried adding the following code to the Nginx default file, but then I receive 502 Bad Gateway.
# Phpmyadmin Configurations 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_param HTTPS on; # <-- add this line fastcgi_pass unix:/var/run/php/php7.0-fpm.sock; fastcgi_index index.php; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; include fastcgi_params; } location ~* ^/phpmyadmin/(.+\.(jpg|jpeg|gif|css|png|js|ico|html|xml|txt))$ { root /usr/share/; } } # Dealing with the uppercased letters location /phpMyAdmin { rewrite ^/* /phpmyadmin last; } I've tried un-commenting fastcgi_param HTTPS on; as my site is using HTTPS but I still receive 502 Bad Gateway. Am I missing a step here? How do I allow Nginx to show phpMyAdmin correctly?
Thank you!