Report this

What is the reason for this report?

Should I use root to start my website?

Posted on January 23, 2015

Hi,

I’m in the process of learning how to use VPS to host my website. I have created LAMP stack and phpmyadmin and have my code ready. Aside from that, I haven’t created any additional users or set any additional security checkpoints yet.

I just wonder, is it ok to start my website, by using this “root” to upload all the file to the “/var/www/” folder and keep moving on from this? Or should I create another user?

Thank you so much!



This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Your server works from www-data user (by default) and this user will not be able to access root’s files, so create new user (for example ‘myuser’) and add myuser to www-data usergroup. Anyway You shouldn’t use root access as default.

This comment has been deleted

The developer cloud

Scale up as you grow — whether you're running one virtual machine or ten thousand.

Get started for free

Sign up and get $200 in credit for your first 60 days with DigitalOcean.*

*This promotional offer applies to new accounts only.