I know you’ve got plesk, can you restart it or Restart nginx. Every time i’ve had this happen it’s due to a change i’ve made in the
/etc/nginx/nginx.conf or any .conf in
/etc/nginx or even other changes.
When battling 500’s likely due to server nginx always
Restart nginx after each change, if possible which with D.O. certainly should be.
I think it’s
systemctl service stop nginx depending on the distro and version. and then
systemctl service start nginx (maybe even restart in some instances, and other instances it’s like a “?” service.nginx restart command. You’ll have to browse the googles for them, there’s a few.
Or if you used homebrew for linux or are locally on mac it would be something like
brew service nginx restart
NOTE: I could have butchered these commands i’m writing mobile off the top My apologies to others, you perfect code monks and Heads of the Board of Forum Board Educators, Etiquette, and Format :)
The other matter I’ve found myself failing at often was php-fpm in my nginx configuration. I had a local version running php7.2-fpm on a @php7.4fpm version. Make sure your path mentioned in your sites-available match up. Thirdly, create a new folder as user sudo mkdir in sites-enabled and this actually helped in one case where I opted not to use the default that was set up and just matched all files up correctly. In my case it was laravel on Ubuntu. Today, it still is so if you chaps have any input on my soon to be thread i’d appreciate any input.
Also if you use git at all you may be using root on a VPS any change you make might undo your work by changing user/group perms back to root.
My one, two, or maybe 3 cents more than anyone wanted on this matter but maybe will keep the next “me” who’s browsing similar topics to see this and say hey I know that, and “no, I dont need to restart nginx, it’s fine.” then suddenly they see this where I had previously thought that exact thing, Boom resolution along with the items listed above.