[foreman-dev] Re: error calling hammer.run() from w/in 'hammer csv subscriptions'

2016-09-02 Thread Tom McKay
Opened a PR that works but I'd like to understand the problem and what
changed, if anyone has any insights.
https://github.com/Katello/hammer-cli-csv/pull/121

On Fri, Sep 2, 2016 at 1:14 PM, Tom McKay  wrote:

> I get an error "RuntimeError (Current textdomain (nil) was not added, use
> FastGettext.add_text_domain !" during a call to hammer.run() from w/in
> another hammer command. Effectively 'hammer csv subscriptions' is calling
> 'hammer subscription upload' from w/in itself. If I add this code[1] prior
> to calling hammer.run() then things work as expected (and as it had
> previously).
>
> What is the proper way to config FastGettext in hammer module?
>
>
> [1] https://github.com/thomasmckay/hammer-cli-csv/
> blob/fastgettext/lib/hammer_cli_csv/subscriptions.rb#L62-L68
>

-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[foreman-dev] error calling hammer.run() from w/in 'hammer csv subscriptions'

2016-09-02 Thread Tom McKay
I get an error "RuntimeError (Current textdomain (nil) was not added, use
FastGettext.add_text_domain !" during a call to hammer.run() from w/in
another hammer command. Effectively 'hammer csv subscriptions' is calling
'hammer subscription upload' from w/in itself. If I add this code[1] prior
to calling hammer.run() then things work as expected (and as it had
previously).

What is the proper way to config FastGettext in hammer module?


[1]
https://github.com/thomasmckay/hammer-cli-csv/blob/fastgettext/lib/hammer_cli_csv/subscriptions.rb#L62-L68

-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [foreman-dev] Re: foreman-proxy rest api

2016-09-02 Thread Dmitri Dolguikh
Here’s a partial list of smart-proxy api:
http://projects.theforeman.org/projects/smart-proxy/wiki/API. Please
keep in mind that the list doesn’t include any of the non-core plugin
apis.

Cheers,
-Dmitri


On Fri, Sep 2, 2016 at 3:29 PM, 'Gennady Voronkov' via foreman-dev
 wrote:
>
>>You can create new endpoints via the plugin API, extending the smart
>>proxy using a new rubygem.
>>http://projects.theforeman.org/projects/foreman/wiki/Smart-Proxy_Plugins
>>contains more information and links to some existing examples.
>>--
>>Dominic Cleal
>>dom...@cleal.org
>
> thanks a lot, may you know all endpoints for foreman-proxy? or tell me
> please how to find out?
>
> --
> 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+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[foreman-dev] Re: foreman-proxy rest api

2016-09-02 Thread 'Gennady Voronkov' via foreman-dev

>You can create new endpoints via the plugin API, extending the smart 
>proxy using a new rubygem. 
>http://projects.theforeman.org/projects/foreman/wiki/Smart-Proxy_Plugins 

 
>contains more information and links to some existing examples. 
>-- 
>Dominic Cleal 
>dom...@cleal.org 

thanks a lot, may you know all endpoints for foreman-proxy? or tell me 
please how to find out?

-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[foreman-dev] PR test maintenance on Foreman tomorrow

2016-09-02 Thread Dominic Cleal
I intend to make some disruptive changes on the PR tests running on the
main Foreman repository tomorrow (Sat 3rd Sept), so please wait if you
wish to open or update PRs that day. This should improve performance
when many PRs are queued.

-- 
Dominic Cleal
domi...@cleal.org

-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [foreman-dev] foreman-proxy rest api

2016-09-02 Thread Dominic Cleal
On 02/09/16 14:40, 'Gennady Voronkov' via foreman-dev wrote:
> Hi all
> does anyone know, how to look at all endpoint for foreman-proxy
> and how to create(add) myself endpoint for foreman-proxy

You can create new endpoints via the plugin API, extending the smart
proxy using a new rubygem.

http://projects.theforeman.org/projects/foreman/wiki/Smart-Proxy_Plugins
contains more information and links to some existing examples.

-- 
Dominic Cleal
domi...@cleal.org

-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[foreman-dev] foreman-proxy rest api

2016-09-02 Thread 'Gennady Voronkov' via foreman-dev
Hi all
does anyone know, how to look at all endpoint for foreman-proxy
and how to create(add) myself endpoint for foreman-proxy
Thanks in advance
BR, Gennady

-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[foreman-dev] New major release of foreman_templates - info for other plugin authors

2016-09-02 Thread Greg Sutcliffe
Hi all,

I just merged foreman_templates PR #27 [1] into master. Most of this is
refactoring, but it does bring one new feature aimed at other plugins.

The new import code will first look for a metadata entry call "model". If
it finds this, it will attempt to call "import!" on whatever model is
specified there (after first calling constantize, of course). See [2] for
the exact code.

This means it's possible for any plugin to define a model with a method
called "import!" and handle what to do with the template passed to it by
foreman_templates, without adding code to foreman_templates itself. This
method does not have to inherit from core's Template type (although for
many things it will make sense to do so) - it needs only to accept the 3
args passed to it and return an appropriate Hash.

The README [3] contains the input/output expectations, and a trivialised
example of a plugin writing templates to disk.

This code is in master, as stated, and I expect to do a gem release soon
(waiting on one more PR). However, the "model" attribute will be ignored in
older versions of foreman_templates, so I may start sending PRs to
community_templates ahead of that release.

Enjoy!

[1] https://github.com/theforeman/foreman_templates/pull/27
[2] https://github.com/theforeman/foreman_templates/blob/master/
app/services/foreman_templates/template_importer.rb#L66
[3]
https://github.com/theforeman/foreman_templates#integration-with-other-foreman-plugins

-- 
Greg
IRC: gwmngilfen

-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[foreman-dev] Discovery 7.0.0 hits nightly repos

2016-09-02 Thread Lukas Zapletal
Hello,

discovery 7.0 is now in nightly repos, the 6.0 was broken for some time
because of strong parameters changes in core and also UEFI patch.

Now it's all fixed. Version 7.0 is mostly bugfix release:

Fixes #16324 - kexec templates work under safemode
Fixes #16041 - Unify accordion styles in show page
Fixes #16105 - Force DNS rebuild when provisioning discovered host
Fixes #15777 - add modal to provision action on show page
 Refs #15750 - added missing strong params for rule
Fixes #16081 - FactValue returns value for .host
Fixes #15750 - strong parameters (v1.13+)

No other features are incoming into the release, we expect only
bugfixes. Please report all issues on RedMine and ping me for blocker
issues so I can prepare patch quickly for Foreman 1.13 RC releases.

Known issues:

All PXE provisioning fails in safemode (patch was merged yesterday in core but
we need to resync templates). This should be fixed during next week. #16318

Autoprovisioning does not set Content Source and View/Media correctly
when Katello plugin is installed. This is a blocker that will be fixed
eventually later on. #16063

-- 
Later,
 Lukas #lzap Zapletal

-- 
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+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.