CentOS SFTP Access Permissions

April 24, 2016 580 views
Let's Encrypt System Tools Applications LEMP CentOS

I think I am having some sort of permissions issues and I am not sure.

Just created my first droplet ever and the steps below are what I have done so far.

Configured SSH Keypair/Access
Created user and added to sudoers
Disabled root logins
Configured firewall to allow http, https, and ssh access
Installed LEMP stack
(Tried to configure Lets Encrypt, but failed. That is another problem for later)

The LEMP stack is functioning correctly and I have access to everything, but when I connect via SFTP using WinSCP I am unable to delete the default index.html file for nginx. Nor am I able to upload any new documents. (I am not using root, I am using the new profile I created and added to sudoers)

I think this may be a permissions issues, but I am not sure?

Thanks :D

1 Answer

This does sound like a permissions issue. The files in the default web root when using nginx will be owned by user and group nginx. You can change the ownership of these files to the new user you created (but nginx may not be able to write new files if this is needed) or you can add your new user to the nginx group.

  • Ryan,

    I added my user to the "nginx" group and I am still unable to make changes to those files.

    I thought this would fix, but it must be something else causing it.

Have another answer? Share your knowledge.