I’m attempting to develop a ZenPack to carry out some data loading from a config file and push it into zenoss via direct dmd manipulation. This is on Zenoss 4.2.5
I’ve got this working when driven by independent user actions in the GUI (via some new menu additions) and when called from inside the ZenPack class in the init file of the ZenPack.
However, I’d also like this to be run from the top level of the init file, so that the config is picked up whenever zenoss is restarted.
When run from inside the zenpack class I can grab a dmd object via app.zport.dmd as the app is passed into the install method.
What I’m having a problem with is obtaining a dmd object to pass to my code from this top level of the init file.
Can anyone suggest a way this can be done from here?