Foreman plugin accessing katello host data like asigned content view

Hi All,

I'm generally interested if it is possible to access from within a
foreman_plugin data from Katello plugin (plugin accesses data from other
plugin).
For example I would like to extract the content-view/asigned repository
information for a given host.

regards,
Daniel

> Hi All,
>
> I'm generally interested if it is possible to access from within a
> foreman_plugin data from Katello plugin (plugin accesses data from other
> plugin).
> For example I would like to extract the content-view/asigned repository
> information for a given host.

Yes, after initialization your plugin should be able to access all
katello properties.

The foreman-docker plugin for instance does different things depending
on whether Katello is available or not, like in:

··· On 01/16, Daniel Kuffner wrote:

regards,
Daniel


You received this message because you are subscribed to the Google Groups “foreman-dev” group.
To unsubscribe from this group and stop receiving emails from it, send an email to foreman-dev+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Daniel Lobato Garcia

@dLobatog

GPG: http://keys.gnupg.net/pks/lookup?op=get&search=0x7A92D6DD38D6DE30
Keybase: elobato (Daniel Lobato Garcia) | Keybase

If there is any specific data that you aren't sure about, feel free to ping
and ask here. Ruby allows you access to almost anything, and there are
certainly some better practices we've discovered over the years for how and
where to do this access to reduce the chance of breakage between releases.

We would also find it interesting to see where and what you';d like
"supported" access to in case that presents an opportunity to build a
supported API for plugin access to Katello.

Eric

··· On Tue, Jan 17, 2017 at 6:39 AM, Daniel Lobato Garcia wrote:

On 01/16, Daniel Kuffner wrote:

Hi All,

I’m generally interested if it is possible to access from within a
foreman_plugin data from Katello plugin (plugin accesses data from other
plugin).
For example I would like to extract the content-view/asigned repository
information for a given host.

Yes, after initialization your plugin should be able to access all
katello properties.

The foreman-docker plugin for instance does different things depending
on whether Katello is available or not, like in:

foreman_docker/app/views at master · theforeman/foreman_docker · GitHub
containers/steps/image.html.erb

regards,
Daniel


You received this message because you are subscribed to the Google
Groups “foreman-dev” group.
To unsubscribe from this group and stop receiving emails from it, send
an email to foreman-dev+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Daniel Lobato Garcia

@dLobatog
blog.daniellobato.me
daniellobato.me

GPG: http://keys.gnupg.net/pks/lookup?op=get&search=0x7A92D6DD38D6DE30
Keybase: elobato (Daniel Lobato Garcia) | Keybase


You received this message because you are subscribed to the Google Groups
“foreman-dev” group.
To unsubscribe from this group and stop receiving emails from it, send an
email to foreman-dev+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Eric D. Helms
Red Hat Engineering

Great, going to dig into the docker plugin first.
thank you,
Daniel