The error message is saying two things:
1st - that the user running Nginx has no access permissions at the error log file: /usr/local/var/log/nginx/error.log
2nd - that the directory of access log file there is no:
/Users/username/code/product/log
I would solve the case as follows:
1º - checking which user is running Nginx; just check the configuration file, through the command:
sudo cat /etc/nginx/nginx.conf | grep user
2º - changing the Nginx log file settings to files that can be accessed by the respective user (in directories that exist, of course)... run the following commands to verify which files are the settings:
cd /etc/nginx
sudo grep -R log *
3º - edit the files (sudo pico nginx.conf
or similar) and restart (sudo service nginx restart
)
Note: the above commands serve for a modern Ubuntu Linux; if your system is another, apply the appropriate adaptations
Can describe the problem?
– rray
Welcome to Stackoverflow, to post a Question, you have to have a question. In your case you just posted an Error, and said it was on
nginx
however we do not know what you are trying to do, we do not have access to your code, much less we know how to proceed to help you, so supplement your question with a Real Question.– Paulo Roberto Rosa