简体   繁体   中英

How to SSH in EC2 as root with cyberduck?

I have an EC2 instance with some php scripts running on Amazon. The folder with the files has permission 755 (chmod 755 folder).

Everytime I login I have to change the folder permissions to change anything to files.

Question: Is it possible to login as root with cyberduck?

Note: I found this link How to use sudo over SFTP with CyberDuck? , but it is from 2010 and I don't know if that info is accurate or not.

If it is a folder that your user should be able to read and write. Give your user account permissions to it...

1) Create a group

sudo groupadd mygroup

2) Add your user account to that group

sudo usermod -a -G mygroup myuser

3) Change the permissions of the folder such that group has execute/modify

sudo chown -R current_owner:mygroup myfolder
sudo chmod 776 myfolder

It is odd you have to change permissions every time. If this folder is deleted and re-created by another process or user, you will need to set the environment variable umask to 776 before creating the files and folders in your script.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM