I recently installed nginx 1.13.1 on an Ubuntu instance in Amazon Lightsail.
Ubuntu version is 16.04 Xenial OS. Nginx was installed using the Nginx.org package repository.
After installation, the default nginx.conf specifies user as:
user nginx;
I started the nginx using the below command:
sudo service nginx start
On checking the status of nginx using:
ps -ef | grep nginx
I found that worker process is owned by nginx user.
Now as per various resources available online, people suggest to use 'www-data' as the user.
My queries related to above scenario is:
Is there any difference in security permissions for nginx and www-data user?
Should I change user to 'www-data' if it is more secure?
I am new to Linux and nginx so any help will be appreciated.