Git + SSH - JadenGil/Jaden-Tech-Journal GitHub Wiki

First I made sure that git is installed on my docker01 machine. Once confirmed, I proceeded to clone my private repository to docker01 using the git clone command with my GitHub repository URL.

Next, I created a directory structure within my local repository to organize my configs using 'mkdir'. After creating the directory structure, I would use the git add command to add my changes to the repository, followed by the git commit command to commit the changes with a message. I then used the git push command to push the changes to GitHub.

When I installed git on mgmt01 I downloaded the 64-bit version of Git and run the installer with default settings. Once installed, I cloned my repository to mgmt01 using the same git clone command used earlier.

I then added the README.md to the directory, and used git add, git commit, and git push commands to commit and push the changes.

Since the README file was incorrect I used the echo command to modify the file and update the repository on mgmt01. To update the local repository on docker01, I used the git pull command to pull the changes from GitHub to my local repository.

To clone my tech journal to web01, I installed git on web01 and used the git clone command with the same URL I used the first time. (after checking I had the right version installed:))

After that, I organized my local repository by creating directories and a script called secure-ssh.sh with nano. After creating the script, I pushed my changes to GitHub.

I then created an RSA keypair on web01 using the ssh-keygen command to create the keys with no passphrase. After creating the keys, I copied the public key to the local repository using the cat command.

On docker01, I used the git pull command to sync my repo with the changes made on web01. Next, I created a user that can only login via RSA private key. I did this manually first and then made a script to do it for me

Finally, I modified secure-ssh to create a passwordless user. I then ran the script on docker01 and tested the passwordless login from web01. and it worked

⚠️ **GitHub.com Fallback** ⚠️