Skip to content

Commit

Permalink
Create passwordless.md
Browse files Browse the repository at this point in the history
  • Loading branch information
monaghaa committed Jun 22, 2020
1 parent 99caf1e commit a0f3acb
Showing 1 changed file with 40 additions and 0 deletions.
40 changes: 40 additions & 0 deletions docs/compute/passwordless.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
## Transferring data to CURC without a password (_command line only_)

_Note: you must be logged in to [campus VPN](https://oit.colorado.edu/services/network-internet-services/vpn) to do a passwordless data transfer to CURC_

### generate an ssh keypair on your local laptop/desktop

You only need to perform this step once. From a local terminal run:

```
ssh-keygen -t ed25519
```

This will create ~/.ssh/id_ed25519 and ~/.ssh/id_ed25519.pub on your local machine (_note: the "~" denotes your home directory).

### Copy the public key to ~/.ssh/authorized_keys on a CURC login node

You only need to perform this step once. From a local terminal run:

```
cat ~/.ssh/id_ed25519.pub | ssh ralphie@login.rc.colorado.edu -T "cat >> ~/.ssh/authorized_keys"
```
...where you should substitute your CURC username for "ralphie"; you will be required to enter your password and accept a Duo push in order to transfer the key.

_Note: If you have trouble running the command above, you can also just login to a CURC login node, open `~/.ssh/authorized_keys` and paste the text from `~/.ssh/id_ed25519.pub` that resides on your local machine.

### Use `rsync` or `scp` to transfer files without a password

Now you are ready to transfer files. Make sure you are logged on campus or logged into CU VPN.

For example, to tranfer a `myfile.txt` from your local machine to your `/projects/$USER` directory on CURC

```
rsync -av ./myfile.txt dtn-new-data.rc.int.colorado.edu:/projects/ralphie/myfile.txt
```

or, you can use scp. Here user `ralphie` transfers to a PetaLibrary allocation called "crdds" that Ralphie has access to:

```
scp ./myfile.txt dtn-new-data.rc.int.colorado.edu:/pl/active/crdds/myfile.txt
```

0 comments on commit a0f3acb

Please sign in to comment.