Just enough GiT for Puppet Automation – Part7

All Posts in this Series



Pushing Local code changes to the master GiT repo

We have made a change to our working copy of the Puppet repo on demo2, but so far we haven’t committed and pushed the change to the master repo. We need to do this so that the changes will be available to all other machines using the repo.
1. Commit the changes:

igurkul@demo2:~$ sudo su – git
$ bash
igurkul@demo2:~$ cd puppet
igurkul@demo2:~/puppet$ git status
# On branch master
# Changes not staged for commit:
# (use “git add …” to update what will be committed)
# (use “git checkout — …” to discard changes in working directory)
# modified: manifests/nodes.pp
no changes added to commit (use “git add” and/or “git commit -a”)
igurkul@demo2:~/puppet$ git add manifests/nodes.pp
igurkul@demo2:~/puppet$ git commit -m “Adding node demo2″ –author=”john@bitfieldconsulting.com”
[master 967cb8b] Adding node demo2

1 file changed, 5 insertions(+)

2. Now push all changes back to the master repo:

igurkul@demo2:~/puppet$ git push
Counting objects: 7, done.
Compressing objects: 100% (4/4), done.
Writing objects: 100% (4/4), 412 bytes, done.
Total 4 (delta 0), reused 0 (delta 0)
0ce98c0..967cb8b master -> master




I have started unixadminschool.com ( aka gurkulindia.com) in 2009 as my own personal reference blog, and later sometime i have realized that my leanings might be helpful for other unixadmins if I manage my knowledge-base in more user friendly format. And the result is today's' unixadminschool.com. You can connect me at - https://www.linkedin.com/in/unixadminschool/

What is in your mind, about this post ? Leave a Reply

  Our next learning article is ready, subscribe it in your email

What is your Learning Goal for Next Six Months ? Talk to us

What is your Learning Goal for Next Six Months ? Talk to us