Remote access to duty-rotation schedules?

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Remote access to duty-rotation schedules?

Aaron Paxson-2
I don't believe ONMS stores the duty-rotation schedules in pgsql.  Is there any way I can access that data remotely?

I would like to send my helpdesk calls to the technician on Duty, as dictated by ONMS.

Possible?

Thanks!

--
Aaron J. Paxson
---------
[hidden email]
http://aaron.thepaxson5.org

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Please read the OpenNMS Mailing List FAQ:
http://www.opennms.org/index.php/Mailing_List_FAQ

opennms-discuss mailing list

To *unsubscribe* or change your subscription options, see the bottom of this page:
https://lists.sourceforge.net/lists/listinfo/opennms-discuss
Reply | Threaded
Open this post in threaded view
|

Re: Remote access to duty-rotation schedules?

Jeff Gehlbach
On Sep 10, 2008, at 5:51 PM, Aaron Paxson wrote:

> I don't believe ONMS stores the duty-rotation schedules in pgsql.  
> Is there any way I can access that data remotely?

The schedules are all stored in the XML config files.  You could make  
them available remotely, but you'd have to parse them and stuff.

> I would like to send my helpdesk calls to the technician on Duty, as  
> dictated by ONMS.

This is kinda quick and dirty, but you could do something like this:

wget -O - --auth-no-challenge --http-user=admin --http-password=admin \
'http://localhost:8980/opennms/admin/userGroupView/roles?operation=view&role=NewRole' 
  \
2>/dev/null | grep -A 6 'Currently On Call'

Then all that's left is to scrape the line formatted like this:

                <span title="Administrator">admin</span>

Assuming you can correlate either the username (inside the <span> tag)  
or the descriptive name (in the "title" attribute) to a phone number,  
SIP URI, or whatever, you should be all set.  Set up a cron job to run  
this command every fifteen minutes and drop the results in a well-
known location, boom you're done.

-jeff

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Please read the OpenNMS Mailing List FAQ:
http://www.opennms.org/index.php/Mailing_List_FAQ

opennms-discuss mailing list

To *unsubscribe* or change your subscription options, see the bottom of this page:
https://lists.sourceforge.net/lists/listinfo/opennms-discuss
Reply | Threaded
Open this post in threaded view
|

Re: Remote access to duty-rotation schedules?

Aaron Paxson-2
Jeff.......

You totally rock!

Aaron


On 9/10/08, Jeff Gehlbach <[hidden email]> wrote:

> On Sep 10, 2008, at 5:51 PM, Aaron Paxson wrote:
>
>> I don't believe ONMS stores the duty-rotation schedules in pgsql.
>> Is there any way I can access that data remotely?
>
> The schedules are all stored in the XML config files.  You could make
> them available remotely, but you'd have to parse them and stuff.
>
>> I would like to send my helpdesk calls to the technician on Duty, as
>> dictated by ONMS.
>
> This is kinda quick and dirty, but you could do something like this:
>
> wget -O - --auth-no-challenge --http-user=admin --http-password=admin \
> 'http://localhost:8980/opennms/admin/userGroupView/roles?operation=view&role=NewRole'
>   \
> 2>/dev/null | grep -A 6 'Currently On Call'
>
> Then all that's left is to scrape the line formatted like this:
>
> <span title="Administrator">admin</span>
>
> Assuming you can correlate either the username (inside the <span> tag)
> or the descriptive name (in the "title" attribute) to a phone number,
> SIP URI, or whatever, you should be all set.  Set up a cron job to run
> this command every fifteen minutes and drop the results in a well-
> known location, boom you're done.
>
> -jeff
>
> -------------------------------------------------------------------------
> This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
> Build the coolest Linux based applications with Moblin SDK & win great
> prizes
> Grand prize is a trip for two to an Open Source event anywhere in the world
> http://moblin-contest.org/redirect.php?banner_id=100&url=/
> _______________________________________________
> Please read the OpenNMS Mailing List FAQ:
> http://www.opennms.org/index.php/Mailing_List_FAQ
>
> opennms-discuss mailing list
>
> To *unsubscribe* or change your subscription options, see the bottom of this
> page:
> https://lists.sourceforge.net/lists/listinfo/opennms-discuss
>

--
Sent from my mobile device

Aaron J. Paxson
---------
[hidden email]
http://aaron.thepaxson5.org

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Please read the OpenNMS Mailing List FAQ:
http://www.opennms.org/index.php/Mailing_List_FAQ

opennms-discuss mailing list

To *unsubscribe* or change your subscription options, see the bottom of this page:
https://lists.sourceforge.net/lists/listinfo/opennms-discuss