Ubuntu under LNMP Development about permissions issues

Source: Internet
Author: User
Go to Ubuntu under PHP development, previously developed under Windowns, directly set the project directory to d:\pathto\nginx\htdoc\www in the editor.
Under Ubuntu the same operation,/usr/local/nginx/htdoc/www set for the project directory in the edit Phpstorm edit, but the prompt does not have permissions, I know that the current user is not authorized to modify the root folder in the file.
How do you usually set up under the development of Ubuntu? are each project to be set chmod or Chown to their current users?

Reply content:

Go to Ubuntu under PHP development, previously developed under Windowns, directly set the project directory to d:\pathto\nginx\htdoc\www in the editor.
Under Ubuntu the same operation,/usr/local/nginx/htdoc/www set for the project directory in the edit Phpstorm edit, but the prompt does not have permissions, I know that the current user is not authorized to modify the root folder in the file.
How do you usually set up under the development of Ubuntu? are each project to be set chmod or Chown to their current users?

I development environment and you have encountered your problem, if you start to install PHP is the use of root identity, then the solution is to remove the original installation, using the user's identity to reinstall.
Nagging, almost all things can be done using the user's identity, the need to use the root authority when using the front plus sudo, as far as possible not to log on as root operation, or the following issues related to permissions need to be changed very cumbersome.

The Ubuntu server needs to 默认 bewww-data:www-data
Phpstorm default is your current user, for example bruce:bruce (Bruce is my name)
Method you can change the execution permissions of Nginx and PHP-FPM to your current user.
Of course I do not recommend that you do this, and I hope you are keeping the respective permissions intact in another directory development, leveraging the ln -s creation of connections to your server directory.

  • Contact Us

    The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

    If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

    A Free Trial That Lets You Build Big!

    Start building with 50+ products and up to 12 months usage for Elastic Compute Service

    • Sales Support

      1 on 1 presale consultation

    • After-Sales Support

      24/7 Technical Support 6 Free Tickets per Quarter Faster Response

    • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.