docauto
By:
docauto

What is the best way to give other developers access to my droplet to help develop my site without having to give them my login details?

October 21, 2014 2.1k views

I am new at developing, can get the boilerplate up and make some changes but would like to give access of the code to others to help me develop the site. Should I host the codes in an outside repository then have it deployed to my droplet, or is there a way to give them access to my consol but using their own login for digitalocean?

1 comment
  • There are different ways to go about this. My preference:

    Create a new user, for example:
    sudo adduser bob
    sudo passwd bob
    sudo mkdir /home/bob
    
    Create a group for people who will be working on your sites:
    sudo addgroup webmasters
    
    add bob to webmasters:
    sudo usermod -aG webmasters bob
    
    give your new group permissions on your website files:
    sudo chown -R www-data:webmasters /var/www
    

    and

    sudo chmod -R 775 /var/www
    
    and finally make a link to your website folder in your new users home folder:
    sudo ln -s /var/www /home/bob/
    

    now your user can login with whatever password you created. There will be a link to the website folders They should have permissions enough to work on your site.

    You can delete that user with:

    sudo userdel bob
    sudo rm -r /home/bob
    
1 Answer

This question was answered by @sierracircle:

There are different ways to go about this. My preference:

Create a new user, for example:
sudo adduser bob
sudo passwd bob
sudo mkdir /home/bob
Create a group for people who will be working on your sites:
sudo addgroup webmasters
add bob to webmasters:
sudo usermod -aG webmasters bob
give your new group permissions on your website files:
sudo chown -R www-data:webmasters /var/www

and

sudo chmod -R 775 /var/www
and finally make a link to your website folder in your new users home folder:
sudo ln -s /var/www /home/bob/

now your user can login with whatever password you created. There will be a link to the website folders They should have permissions enough to work on your site.

You can delete that user with:

sudo userdel bob
sudo rm -r /home/bob

View the original comment

Have another answer? Share your knowledge.