[rancid] Email notifications - summary at the top

Jon Lewis jlewis at lewis.org
Thu Sep 2 04:41:51 UTC 2010


I must have added this to ours way back when I installed it.  It's just a 
tiny change in control_rancid adding the diffstat command.  Obviously, 
make sure you have diffstat installed.

# Mail out the diffs (if there are any).
if [ -s $TMP.diff ]; then
     sendmail -t <<EMAIL
To: $mailrcpt
Subject: $subject
Precedence: bulk

`diffstat $TMP.diff`

`cat $TMP.diff`
EMAIL


On Wed, 1 Sep 2010, Brian G wrote:

>
>  Actually, this was the rancid-core and rancid-util package that got 
> installed from the debian (lenny) release.  Not sure what they changed in 
> this release to do this.  (or what file to be specific)
>
> --------------------------------------------------
> From: "Brian G" <xenophon21 at hotmail.com>
> Sent: Wednesday, September 01, 2010 7:56 PM
> To: "john heasley" <heas at shrubbery.net>
> Subject: Re: [rancid] Email notifications - summary at the top
>
>> Happen to know which file got modified to make it do that?  I was looking 
>> to add this, as it's neat to see what changed at the top of the email.
>> 
>> --------------------------------------------------
>> From: "john heasley" <heas at shrubbery.net>
>> Sent: Wednesday, September 01, 2010 5:59 PM
>> To: "Brian G" <xenophon21 at hotmail.com>
>> Subject: Re: [rancid] Email notifications - summary at the top
>> 
>>> Wed, Sep 01, 2010 at 01:54:37PM -0500, Brian G:
>>>> 
>>>> I've recently acquired a server that is running rancid (2.3.4).  I 
>>>> noticed the email notifications do not include a summary of what files 
>>>> have changes.
>>>> 
>>>> Here is an example from another server I run which shows a quick summary 
>>>> at the top of the email on what routers "changed"
>>>> 
>>>>  bur-7606     |   16 ++++++----------
>>>>  menoalls-7606 |   20 ++++++++++----------
>>>>  ville-7609      |   15 ++++++---------
>>>>  3 files changed, 22 insertions(+), 29 deletions(-)
>>>> 
>>>> 
>>>> How can I get 2.3.4 to include the "summary"?  Could it be differences in 
>>>> the diff version or cvsweb installed?
>>>> 
>>>> Thanks,
>>>> Brian
>>>> _______________________________________________
>>>> Rancid-discuss mailing list
>>>> Rancid-discuss at shrubbery.net
>>>> http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss
>>> 
>>> it was a local change.
>>> 
> _______________________________________________
> Rancid-discuss mailing list
> Rancid-discuss at shrubbery.net
> http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss
>

----------------------------------------------------------------------
  Jon Lewis, MCP :)           |  I route
  Senior Network Engineer     |  therefore you are
  Atlantic Net                |
_________ http://www.lewis.org/~jlewis/pgp for PGP public key_________


More information about the Rancid-discuss mailing list