Mailing List Archive

Howto setup Rancid with Git on Debian?
Hello folks,

i've searched the web, this list, contents in the package etc. but didn't find any up to date information on how to setup Rancid with Git on Debian.

I've installed rancid via apt-get (rancid ver. 3.6.2-2) on Debian 9. Git is ver. 2.11.

Any information on this would be appreciated!

Thanks in advance.
Re: Howto setup Rancid with Git on Debian? [ In reply to ]
On Thu, Jan 11, 2018 at 11:02 AM, ACS Solutions Network
<network@acs-europe.de> wrote:
> Hello folks,
>
>
>
> i’ve searched the web, this list, contents in the package etc. but didn’t
> find any up to date information on how to setup Rancid with Git on Debian.
>
>
>
> I’ve installed rancid via apt-get (rancid ver. 3.6.2-2) on Debian 9. Git is
> ver. 2.11.
>

<10 seconds with google found

https://www.cryptomonkeys.com/2016/11/rancid-git/
http://opennodecloud.com/howto/2014/05/08/howto-about-rancid.html

I do not know if the Debian packaged 3.6.2 includes git support.

Cheers

_______________________________________________
Rancid-discuss mailing list
Rancid-discuss@shrubbery.net
http://www.shrubbery.net/mailman/listinfo/rancid-discuss
Re: Howto setup Rancid with Git on Debian? [ In reply to ]
Whether its Debian or another distro, the basic setup is still the same. I did the same thing on CentOS. V3.6.2 has a bug when running the configure script. Check out:
http://www.shrubbery.net/pipermail/rancid-discuss/2017-July/009735.html

As for the Git part, rancid uses a local git server that it creates the folder structure for. Each rancid group is its gets own Git repo. The key is really the rancid config file. Set RCSSYS=”git” and it will do the heavy lifting. If you need the stuff to go to a remote repo, then you will need to make the local Git do blind commits to the remote repo. That’s something one of my server admins took care of, so I’m not sure exactly how he did it.

Chris




Chris Gauthier Senior Network Engineer | comScore, Inc.
t +1 (503) 331-2704 |
cgauthier@comscore.com
317 SW Alder Street, Suite 700 | Portland, OR 97204 United States
comscore.com
???This e-mail (including any attachments) may contain information that is private, confidential, or protected by attorney-client or other privilege. If you received this e-mail in error, please delete it from your system and notify sender.
-----Original Message-----
From: Rancid-discuss <rancid-discuss-bounces@shrubbery.net> on behalf of shouldbe q931 <shouldbeq931@gmail.com>
Date: Thursday, January 11, 2018 at 4:46 AM
To: ACS Solutions Network <network@acs-europe.de>
Cc: "rancid-discuss@shrubbery.net" <rancid-discuss@shrubbery.net>
Subject: Re: [rancid] Howto setup Rancid with Git on Debian?

On Thu, Jan 11, 2018 at 11:02 AM, ACS Solutions Network
<network@acs-europe.de> wrote:
> Hello folks,
>
>
>
> i’ve searched the web, this list, contents in the package etc. but didn’t
> find any up to date information on how to setup Rancid with Git on Debian.
>
>
>
> I’ve installed rancid via apt-get (rancid ver. 3.6.2-2) on Debian 9. Git is
> ver. 2.11.
>

<10 seconds with google found

https://www.cryptomonkeys.com/2016/11/rancid-git/
http://opennodecloud.com/howto/2014/05/08/howto-about-rancid.html

I do not know if the Debian packaged 3.6.2 includes git support.

Cheers

_______________________________________________
Rancid-discuss mailing list
Rancid-discuss@shrubbery.net
http://www.shrubbery.net/mailman/listinfo/rancid-discuss
Re: Howto setup Rancid with Git on Debian? [ In reply to ]
Thu, Jan 11, 2018 at 12:37:54PM +0000, shouldbe q931:
> On Thu, Jan 11, 2018 at 11:02 AM, ACS Solutions Network
> <network@acs-europe.de> wrote:
> > Hello folks,
> >
> >
> >
> > i’ve searched the web, this list, contents in the package etc. but didn’t
> > find any up to date information on how to setup Rancid with Git on Debian.
> >
> >
> >
> > I’ve installed rancid via apt-get (rancid ver. 3.6.2-2) on Debian 9. Git is
> > ver. 2.11.
> >
>
> <10 seconds with google found
>
> https://www.cryptomonkeys.com/2016/11/rancid-git/
> http://opennodecloud.com/howto/2014/05/08/howto-about-rancid.html
>
> I do not know if the Debian packaged 3.6.2 includes git support.

I'd recommend using 3.7 for git. A minor fix for git, but will make it
easier, IMO.

_______________________________________________
Rancid-discuss mailing list
Rancid-discuss@shrubbery.net
http://www.shrubbery.net/mailman/listinfo/rancid-discuss
Re: Howto setup Rancid with Git on Debian? [ In reply to ]
Thu, Jan 11, 2018 at 03:20:20PM +0000, Gauthier, Chris:
> As for the Git part, rancid uses a local git server that it creates the folder structure for. Each rancid group is its gets own Git repo. The key is really the rancid config file. Set RCSSYS=”git” and it will do the heavy lifting. If you need the stuff to go to a remote repo, then you will need to make the local Git do blind commits to the remote repo. That’s something one of my server admins took care of, so I’m not sure exactly how he did it.

Add a remote to a given rancid group: https://help.github.com/articles/adding-a-remote/
add to the rancid-run cronjob, a 'git push newremote'

cd ~rancid/group
git remote add foo giturl
... rancid-run; cd ~rancid/group; git push foo

add a second push destination (remote should not require auth) to origin
and rancid will push to it each run.
cd ~rancid/group
git remote add foo giturl
git remote set-url --add --push origin `git remote get-url --push origin`
git remote set-url --add --push origin `git remote get-url --push foo`


_______________________________________________
Rancid-discuss mailing list
Rancid-discuss@shrubbery.net
http://www.shrubbery.net/mailman/listinfo/rancid-discuss
Re: Howto setup Rancid with Git on Debian? [ In reply to ]
In my environment, we did it slightly differently. My environment was this:

/var/rancid/rancid is a working local git checkout
/var/rancid/git/rancid is the local git 'master'
/var/rancid/git/rancid/hooks/post-receive has what you're looking for:
user@host# cat post-receive
#!/bin/bash


# ---------------------------------------------
# keep remote git copy up to date
# ---------------------------------------------

/usr/bin/git push -u <REMOTE_GIT_SERVER_NAME> <REMOTE_GIT_REPO_NAME>

To make that work, you must run this command to add the remote:

git remote add <REMOTE_GIT_SERVER> <URL_TO_REPO>

Docs for the remote add are at https://help.github.com/articles/adding-a-remote/.

--Chris



Chris Gauthier Senior Network Engineer | comScore, Inc.
t +1 (503) 331-2704 |
cgauthier@comscore.com
317 SW Alder Street, Suite 700 | Portland, OR 97204 United States
comscore.com
???This e-mail (including any attachments) may contain information that is private, confidential, or protected by attorney-client or other privilege. If you received this e-mail in error, please delete it from your system and notify sender.
-----Original Message-----
From: heasley <heas@shrubbery.net>
Date: Thursday, January 11, 2018 at 9:53 AM
To: "Gauthier, Chris" <cgauthier@comscore.com>
Cc: "rancid-discuss@shrubbery.net" <rancid-discuss@shrubbery.net>
Subject: Re: [rancid] Howto setup Rancid with Git on Debian?

Thu, Jan 11, 2018 at 03:20:20PM +0000, Gauthier, Chris:
> As for the Git part, rancid uses a local git server that it creates the folder structure for. Each rancid group is its gets own Git repo. The key is really the rancid config file. Set RCSSYS=”git” and it will do the heavy lifting. If you need the stuff to go to a remote repo, then you will need to make the local Git do blind commits to the remote repo. That’s something one of my server admins took care of, so I’m not sure exactly how he did it.

Add a remote to a given rancid group: https://help.github.com/articles/adding-a-remote/
add to the rancid-run cronjob, a 'git push newremote'

cd ~rancid/group
git remote add foo giturl
... rancid-run; cd ~rancid/group; git push foo

add a second push destination (remote should not require auth) to origin
and rancid will push to it each run.
cd ~rancid/group
git remote add foo giturl
git remote set-url --add --push origin `git remote get-url --push origin`
git remote set-url --add --push origin `git remote get-url --push foo`
Re: Howto setup Rancid with Git on Debian? [ In reply to ]
Thank you very much Chris and please excuse the late heads up. I didn‘t thought it was just setting RCSSYS=”git” – pretty straight forward.

Von: Rancid-discuss [mailto:rancid-discuss-bounces@shrubbery.net] Im Auftrag von Gauthier, Chris
Gesendet: Donnerstag, 11. Januar 2018 16:20
An: rancid-discuss@shrubbery.net
Betreff: Re: [rancid] Howto setup Rancid with Git on Debian?

Whether its Debian or another distro, the basic setup is still the same. I did the same thing on CentOS. V3.6.2 has a bug when running the configure script. Check out:
http://www.shrubbery.net/pipermail/rancid-discuss/2017-July/009735.html

As for the Git part, rancid uses a local git server that it creates the folder structure for. Each rancid group is its gets own Git repo. The key is really the rancid config file. Set RCSSYS=”git” and it will do the heavy lifting. If you need the stuff to go to a remote repo, then you will need to make the local Git do blind commits to the remote repo. That’s something one of my server admins took care of, so I’m not sure exactly how he did it.

Chris


Chris

Gauthier

Senior Network Engineer

|

comScore, Inc.



t +1 (503) 331-2704<tel:(503)%20331-2704>

|

cgauthier@comscore.com<mailto:cgauthier@comscore.com>



317 SW Alder Street, Suite 700

|

Portland, OR 97204

United States




comscore.com<http://www.comscore.com/>



???This e-mail (including any attachments) may contain information that is private, confidential, or protected by attorney-client or other privilege. If you received this e-mail in error, please delete it from your system and notify sender.






-----Original Message-----
From: Rancid-discuss <rancid-discuss-bounces@shrubbery.net<mailto:rancid-discuss-bounces@shrubbery.net>> on behalf of shouldbe q931 <shouldbeq931@gmail.com<mailto:shouldbeq931@gmail.com>>
Date: Thursday, January 11, 2018 at 4:46 AM
To: ACS Solutions Network <network@acs-europe.de<mailto:network@acs-europe.de>>
Cc: "rancid-discuss@shrubbery.net<mailto:rancid-discuss@shrubbery.net>" <rancid-discuss@shrubbery.net<mailto:rancid-discuss@shrubbery.net>>
Subject: Re: [rancid] Howto setup Rancid with Git on Debian?

On Thu, Jan 11, 2018 at 11:02 AM, ACS Solutions Network
<network@acs-europe.de<mailto:network@acs-europe.de>> wrote:
> Hello folks,
>
>
>
> i’ve searched the web, this list, contents in the package etc. but didn’t
> find any up to date information on how to setup Rancid with Git on Debian.
>
>
>
> I’ve installed rancid via apt-get (rancid ver. 3.6.2-2) on Debian 9. Git is
> ver. 2.11.
>

<10 seconds with google found

https://www.cryptomonkeys.com/2016/11/rancid-git/
http://opennodecloud.com/howto/2014/05/08/howto-about-rancid.html

I do not know if the Debian packaged 3.6.2 includes git support.

Cheers

_______________________________________________
Rancid-discuss mailing list
Rancid-discuss@shrubbery.net<mailto:Rancid-discuss@shrubbery.net>
http://www.shrubbery.net/mailman/listinfo/rancid-discuss