Please Help

Tom Moore Tom.Moore at sas.com
Thu Jul 19 22:48:59 CEST 2007


Greetings,

I'm working with Galen on getting this set up correctly, and here are the problems I'm running into:


First, I've set up the site specific pages as described, i.e. I was using the "custgroup blah blah' moniker in the bb-hosts file, but have now moved to having bbgen call a stripped down version of the bb-hosts file of only the machines I want the special group to see.  i.e. in hobbitlaunch.cfg

[cust-display]
        ENVFILE /usr/local/hobbit/server/etc/hobbitserver.cfg
        CMD /usr/local/hobbit/server/ext/cust-display.sh
        LOGFILE $HOBBITCLIENTHOME/logs/bb-display.log
        INTERVAL 1m


And the cust-display.sh file contains:

#!/bin/sh
BBWEB="/hobbit/cust"
BBHOSTS=/usr/local/hobbit/server/etc/bb-hosts-cust
BBSKIN="$BBSERVERWWWURL/cust/gifs"
BBMENUSKIN="$BBSERVERWWWURL/cust/menu"
BBHELPSKIN="$BBSERVERWWWURL/cust/help"               # Hobbit URL prefix for the online help files.
BBREPURL="$BBSERVERWWWURL/cust/rep"                  # Hobbit URL prefix for the Hobbit availability reports
BBSNAPURL="$BBSERVERWWWURL/cust/snap"                # Hobbit URL prefix for the Hobbit snapshots
$BBHOME/bin/bbgen --pageset=cust --template=cust $BBHOME/www/cust/


I have created cust_header/cust_footer files in the "/server/web" directory, and everything creates fine in the "http://site/hobbit/cust" web link.  I have enabled apache to only allow the special users to visit the site via http://site/hobbit/cust, and not have access to /hobbit.  I've also enabled them to run things in the cgi-bin script directory.  This works fine for just showing them the main page with a status.

I want them to be able to run metric/snapshot reports on specific machines only.  The problem is the menu options allow them to see all the servers in the environment, not just the ones in their specific bb-hosts-cust file.  I've even attempted to manually create a cgi-bin directory under the /hobbit/cust location and edit each cgi sh script (adding some environ vars for the BBSERVERCGIURL etc), but to no avail.  

I guess my big question is where does a script such as hobbit-hostgraphs.sh grab its list of servers to show in the choice pane?  If I can restrict these scripts to only report on the servers in the bb-hosts-cust file, I believe I'll have this set up like a charm.  Also, can I set up custom templates for files other than header and footer?  I.e. if I want to keep the menu option when a person clicks on CPU, then the graphs_footer file which is a symlink to bb_footer gets pulled in instead of a custom graphs footer.  I get the access denied to the menu due to my apache restrictions on /hobbit since it's pulling the URL "/hobbit/menu/menu.js" instead of my /hobbit/cust/menu/menu.js link

Thanks,
Tom






On Thu, 2007-07-19 at 14:41 -0400, Galen Johnson wrote:
> We are tryingto set up site specific pages to allow different groups to view only their specific servers (and limit the tests they see).  We also want to prevent them from being able to see the menu options.  This is easy for the main pages but when you drill into the monitors the menu reappears.  What do we have to add/edit to prevent this behavior.  I was able to accomplish this with bbgen by just duplicating the templates folder and editing each of the different header/footer combos.
> 
TO make it so the menus disappear you can create custom headers and
footers,  just copy your bb_header and bb_footer to "pagename"_header
and "pagename"_footer   then modify as needed.

Example:  in your bb_host file you have a page setup like    page UNIX
Unix Servers

so your files would be UNIX_header and UNIX_footer

We do this very thing, this way specific user can only see the pages
they need to see.  Make sure you remove the reference to the menus in
the footer file

Trent

> I've looked at this (and will probably use it) http://www.hswn.dk/hobbiton/2006/06/msg00184.html.  However, we're a little concerned about some of the possible bleedthrough for the cgi scripts. 
> 
> =G=
> 
> To unsubscribe from the hobbit list, send an e-mail to
> hobbit-unsubscribe (at) hswn.dk
> 
> 




More information about the Xymon mailing list