• If you are still using CentOS 7.9, it's time to convert to Alma 8 with the free centos2alma tool by Plesk or Plesk Migrator. Please let us know your experiences or concerns in this thread:
    CentOS2Alma discussion

Issue Invalid nginx configuration: nginx: [emerg] invalid number of arguments in "add_header"

I think that this could be an issue with the Nginx version. One possible solution could be to enclose value and parameters in single quotes and to omit other single quotes inside the parameter string. Example:
Code:
add_header 'Content-Security-Policy' 'default-src self unsafe-inline *.akamai.net *.doubleclick.net [... add more as required ...]; font-src self fonts.googleapis.com fonts.gstatic.com';
 
Last edited:
Back
Top