Skip to the content.

Lab Report 3

SSH Config, GitHub Access, and Copying Whole Directories


This lab report contains the following:

Screenshots / GIFs will be included in spoilers as to not take up uncessary space.

» This is a spoiler, Click Me! This is the inside of a spoiler where images will be located!

1. Streamlining SSH Configuration

Using SSH Keys instead of a password made connecting to the remote server easier. Adding the host to the /.ssh/config file makes the process of remote connecting even faster. I added a few lines shown in the first image into the config file using TextEdit. Then, in the second image, I demonstrated logging in with the ssh command using the nickname that I gave the host in the config file. Finally, in the last image, I demonstrated copying a file over to the remote server using the scp command. This was all much faster and easier!

» SSH Configuration File SSH Configuration File
» Quickly Logging in to Remote Server Using SSH Command SSH Login
» Quickly Copying a File Using SCP Command SCP

2. Setting up GitHub Access from ieng6

Cloning a GitHub Repository to the remote server using its link only allows limited access to the repository. (Ex. Checking the status and pulling updates). If we want to commit and push changes, further authentication needs to be set-up. I went through this process, and created SSH keys to do so. Shown in the first spoiler are the locations of the public key (~/.ssh) on the remote server and on GitHub. Shown in the second spoiler is the location of the private key on the remote server (also in the ~/.ssh folder). In the third spoiler, I staged, committed, and pushed a change to GitHub. Lastly, the fourth spoiler and accompanying link shows the commit.

» Public Key Location Public Key on Remote Server Public Key on GitHub
» Private Key Location Private Key on Remote Server
» GitHub Commands on Remote Server GitHub Commands on Remote Server
» GitHub Commit Log + Link Commit from Remote Server Commit from Remote Server

3. Copying Whole Directories With scp -r

Copying an entire folder to a remote server is as easy as adding the -r flag to the scp command. In the first image, I demonstrate copying the entirety of the MarkdownParse folder. In the second image, I compiled and ran tests on the remote server in the directory that I had just copied over. In the last image, I demonstrated copying a directory, compiling, and running tests, all in one command using quotes and semi-colons.

» Copying an Entire Directory Copying an Entire Directory
» Testing on the Remote Server Using Copied Directory Testing with Copied Directory
» Copying an Entire Directory and Testing in One Command Combining Commands

This line was added from the ieng6 server!