I uninstalled AAPanel using the command:
wget -O uninstall.sh http://download.bt.cn/install/bt-uninstall.sh && bash uninstall.sh
Then I reinstalled it using the command:
URL=https://www.aapanel.com/script/install_7.0_en.sh && if [ -f /usr/bin/curl ];then curl -ksSO "$URL" ;else wget --no-check-certificate -O install_7.0_en.sh "$URL";fi;bash install_7.0_en.sh aapanel
After that, Nginx started working. I’m not sure of the cause, but this is the third time this month my Nginx has encountered an issue.