Getting Started with Ansible 03 - Setting up the Git Repo

From Wiki
Jump to navigation Jump to search


Ansible is an incredible configuration management and provisioning utility that enables you to automate all the things. In this series, you'll learn everything you need to know in order to use Ansible for your day-to-day administration duties. In part 3, we take a look at another foundational concept - Git. Everyone who effectively implements automation uses Git, and in this video, we look into creating a repository and how to push changes.

Relevant Links
Original Video

Check if git is installed

 which git

Install git

 sudo apt update
 sudo apt install git

Create user config for git

 git config --global "First Last"
 git config --global ""

Check the status of your git repository

 git status

Stage the file (after making changes) to be included in the next git commit

 git add

Set up the file to be included in a commit

 git commit -m "Updated readme file, initial commit"

Send the commit to Github

 git push origin master