Skip to content

Commit

Permalink
fixed shell op order for sudo
Browse files Browse the repository at this point in the history
  • Loading branch information
jonluca committed Mar 25, 2018
1 parent 002faf8 commit ff0ba6c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lesson-6/README.md
Expand Up @@ -88,7 +88,7 @@ Then you'll want to set SSH up with
mkdir ~/.ssh
chmod 700 ~/.ssh
cd ~/.ssh
sudo cp /root/.ssh/authorized_keys . ; sudo rm /root/.ssh/authorized_keys; sudo chown `whoami` authorized_keys; chmod 600 ~/.ssh/authorized_keys
sudo cp /root/.ssh/authorized_keys . && sudo rm /root/.ssh/authorized_keys && sudo chown `whoami` authorized_keys && sudo chmod 600 ~/.ssh/authorized_keys
```

Let's go over what this is doing - it creates the ssh directory, and sets the correct permissions. Then we enter it, copy the ssh key we originally set up for root and delete it for root, then take ownership of the file. Finally, we change the permissions of the actual authorized keys file.
Expand Down

0 comments on commit ff0ba6c

Please sign in to comment.