Re: [foreman-dev] Be sure to import your product content data for Katello 3.6

2017-12-19 Thread JT
It should be run on dev boxes that were built before the installer was
updated [1]. Regarding the foreman-tasks: I suppose that we actually do not
need to require foreman-tasks to be running in order to run that rake task.
If I recall correctly it did work fine for me so long as I had the rails
server running in another process. Let me know if that works and if not I
can open a PR with the fix.

Jonathon

[1]
https://github.com/Katello/katello-installer/commit/a03749491f344458a5b52acadcf21526c66b7c65

On Tue, Dec 19, 2017 at 10:02 PM, Walden Raines  wrote:

> Is this also meant to be ran on dev boxes?  I don't have foreman-tasks
> running so I get the following:
>
> 2017-12-20T02:58:34 [app] [W] foreman-tasks service not running or is not
> ready yet
>
> Thanks,
> Walden
>
>
> On Thu, Dec 7, 2017 at 1:51 PM, Jonathon Turel  wrote:
>
>>
>>
>> On Thursday, December 7, 2017 at 6:04:45 AM UTC-5, Ewoud Kohl van
>> Wijngaarden wrote:
>>>
>>> On Wed, Dec 06, 2017 at 07:07:05AM -0800, Jonathon Turel wrote:
>>> >A change
>>> >>> bc9ad563e1b14c4161207b3e>
>>> >landed in Katello yesterday which introduced a new pattern of importing
>>> >product content information from Candlepin into the Katello DB. This is
>>> in
>>> >support of some new feature work and means that Candlepin will no
>>> longer be
>>> >consulted for that information until it's time to be refreshed. All
>>> areas
>>> >of Katello which use product content data are affected such as the Red
>>> Hat
>>> >Repositories page and several APIs.
>>> >
>>> >In order to populate your local cache, please run `rake
>>> >katello:upgrades:3.6:import_product_content`. From that point on the
>>> cache
>>> >should be updated through ordinary use of Katello - importing
>>> manifests,
>>> >etc. This step is not necessary unless you have a manifest imported
>>> and/or
>>> >custom products created.
>>> >
>>> >I'm working on a change for the installer to do the same import and
>>> I'll
>>> >update this thread once it's ready for review & test.
>>> >
>>> >Let me know if you have problems, questions, or concerns.
>>>
>>> Perhaps this is unrelated and not even possible, but I'd like to know if
>>> we could change database provisioning/seeding to not require candlepin.
>>> Currently for the organization a matching org in candlepin is created.
>>> That's a dependency that ideally shouldn't be there. Do you see this as
>>> an option?
>>>
>>
>> I'd have to look into that, but I think I see the merit. Maybe opening an
>> issue is appropriate here?
>>
>>
>> --
>> 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 a topic in the
> Google Groups "foreman-dev" group.
> To unsubscribe from this topic, visit https://groups.google.com/d/
> topic/foreman-dev/mNAikpyNDFs/unsubscribe.
> To unsubscribe from this group and all its topics, 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.


Re: [foreman-dev] Introducing #theforeman-dev-ui, an experiment

2017-12-19 Thread Walden Raines
> BTW I can add it to the Matrix Foreman community if you OP me on the
> channel.

You'll have to talk to Ohad about that, he's the only one with ops
currently.

> Facilitate, yes. Also could potentially exclude people too, especially
> if they don't see this thread. If this channel persists after your poll,
> please do send PRs to the website etc so that *new* people to the chat
> community know where to find discussions.

Will do.

Thanks,
Walden


On Fri, Dec 15, 2017 at 7:38 PM, Greg Sutcliffe 
wrote:

> On 14/12/17 16:04, Walden Raines wrote:
> > The UX team is playing with the idea of forking UI discussions out
> > into a separate channel.  We will do a month long experiment and see
> > how it goes.
> >
> > *Background:*  The irc channel #theforeman-dev is very busy and
> > there are often times multiple conversations taking place
> > simultaneously.
>
> Whilst I'm generally against fragmentation of similar discussion types
> (i.e dev chat in this case), I can see why you want to test this out.
> Will be interested in seeing your results.
>
> BTW I can add it to the Matrix Foreman community if you OP me on the
> channel.
>
> > *Hypothesis:*  By using the irc channel #theforeman-dev-ui
> > conversations will be more relevant to those who are concerned
> > mainly with UI topics. Having a smaller channel will also facilitate
> > more conversation because of this focus.
>
> Facilitate, yes. Also could potentially exclude people too, especially
> if they don't see this thread. If this channel persists after your poll,
> please do send PRs to the website etc so that *new* people to the chat
> community know where to find discussions.
>
> Greg
>
> --
> 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.


Re: [foreman-dev] Be sure to import your product content data for Katello 3.6

2017-12-19 Thread Walden Raines
Is this also meant to be ran on dev boxes?  I don't have foreman-tasks
running so I get the following:

2017-12-20T02:58:34 [app] [W] foreman-tasks service not running or is not
ready yet

Thanks,
Walden


On Thu, Dec 7, 2017 at 1:51 PM, Jonathon Turel  wrote:

>
>
> On Thursday, December 7, 2017 at 6:04:45 AM UTC-5, Ewoud Kohl van
> Wijngaarden wrote:
>>
>> On Wed, Dec 06, 2017 at 07:07:05AM -0800, Jonathon Turel wrote:
>> >A change
>> >> bc9ad563e1b14c4161207b3e>
>> >landed in Katello yesterday which introduced a new pattern of importing
>> >product content information from Candlepin into the Katello DB. This is
>> in
>> >support of some new feature work and means that Candlepin will no longer
>> be
>> >consulted for that information until it's time to be refreshed. All
>> areas
>> >of Katello which use product content data are affected such as the Red
>> Hat
>> >Repositories page and several APIs.
>> >
>> >In order to populate your local cache, please run `rake
>> >katello:upgrades:3.6:import_product_content`. From that point on the
>> cache
>> >should be updated through ordinary use of Katello - importing manifests,
>> >etc. This step is not necessary unless you have a manifest imported
>> and/or
>> >custom products created.
>> >
>> >I'm working on a change for the installer to do the same import and I'll
>> >update this thread once it's ready for review & test.
>> >
>> >Let me know if you have problems, questions, or concerns.
>>
>> Perhaps this is unrelated and not even possible, but I'd like to know if
>> we could change database provisioning/seeding to not require candlepin.
>> Currently for the organization a matching org in candlepin is created.
>> That's a dependency that ideally shouldn't be there. Do you see this as
>> an option?
>>
>
> I'd have to look into that, but I think I see the merit. Maybe opening an
> issue is appropriate here?
>
>
> --
> 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.


Re: [foreman-dev] Re: Friday tip of the day: use 'jq' to parse json

2017-12-19 Thread Derek Wright
You can access the value  directly as if it were a javascript property: jq
-r .value - Check the online docs, there are tons of options for
mapping/fitlering/selecting/etc... This is probably thee best tool for
working with api's on the command line.

Also getting back to your actual question, use quotes: jq

On Tue, Dec 19, 2017 at 6:36 PM, James Shewey  wrote:

> Any idea how to make the output pipe-able? Eg:
>
> echo '{"value": "New", "onclick": "CreateNewDoc()"}' | jq
>
> works well and, as expected, I get:
>
> {
>   "value": "New",
>   "onclick": "CreateNewDoc()"
> }
>
> But I can't pipe that output to anything else and if I do:
>
> echo '{"value": "New", "onclick": "CreateNewDoc()"}' | jq | grep value
>
> this just errors out printing the tool usage guidelines.
>
> On Friday, December 8, 2017 at 2:00:11 PM UTC-7, Tom McKay wrote:
>>
>> @daviddavis reminded me of a nice utility I learned about recently:
>> jq[1]. I use it quite often in scripts involving container images where I
>> need the long sha256 to reference them.
>>
>> sudo skopeo inspect --raw docker-daemon:satellite.exampl
>> e.com:5000/examplecorp-docker_hub-alpine:3.4 | jq '.config | .digest'
>>
>> Enjoy!
>>
>> [1] https://stedolan.github.io/jq/tutorial/
>>
> --
> 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: Friday tip of the day: use 'jq' to parse json

2017-12-19 Thread James Shewey
Any idea how to make the output pipe-able? Eg:

echo '{"value": "New", "onclick": "CreateNewDoc()"}' | jq

works well and, as expected, I get:

{
  "value": "New",
  "onclick": "CreateNewDoc()"
}

But I can't pipe that output to anything else and if I do:

echo '{"value": "New", "onclick": "CreateNewDoc()"}' | jq | grep value

this just errors out printing the tool usage guidelines.

On Friday, December 8, 2017 at 2:00:11 PM UTC-7, Tom McKay wrote:
>
> @daviddavis reminded me of a nice utility I learned about recently: jq[1]. 
> I use it quite often in scripts involving container images where I need the 
> long sha256 to reference them.
>
> sudo skopeo inspect --raw docker-daemon:
> satellite.example.com:5000/examplecorp-docker_hub-alpine:3.4 | jq 
> '.config | .digest'
>
> Enjoy!
>
> [1] https://stedolan.github.io/jq/tutorial/
>

-- 
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] Code owners attempt 2

2017-12-19 Thread Ewoud Kohl van Wijngaarden

Hello all,

A while ago I proposed code owners for the packaging files. We tried 
this[1] but didn't work in our setup. It turns out that those mentioned 
as owners need permissions on the repository. In our case the packaging 
team (not individual members) has no permission.


There are 3 options:

1) Remove the file since it doesn't work
2) Create a packaging-core group with the intersection of both groups
3) Give @theforeman/packaging permissions on core

Personally I'd really like us to work together better and think this 
could reduce our packaging issues but have no preference between 2 or 3.


[1]: https://github.com/theforeman/foreman/blob/develop/.github/CODEOWNERS

--
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 form helpers and reusing definitions from server side

2017-12-19 Thread Marek Hulán
Hello

I'd like to bring into awareness a discussion that's going on in bookmarks PR 
[1]. This PR demonstrates how to do client side validations using new 
components for forms. E.g. this is how we define that the field is required 
and can't be too long [2]. We have similar validations defined in our model.

One concern I had is that we'll duplicate the definition, both in UI and our 
data model. I'd prefer to have UI validation rendered based on server 
definition. There are cases where the UI field is not related to the specific 
model attribute so we also need the option to explicitly define client 
validations.

Similarly, strings that are normally rendered server side are now duplicated 
at [3]. That can end up in out of sync error messages for users using UI and 
API.

Of course this can be refactored later, but if we start to hardcode too many 
things, the motivation for later refactoring will be lower. Also I'd like to 
have good form helpers from the beginning since changes to them will have 
impact on many plugins later.

I'm definitely not going to block the PR on this. But I'd like to hear 
opinions of others, suggestions for improvements or any other feedback. 

[1] https://github.com/theforeman/foreman/pull/4807
[2] https://github.com/theforeman/foreman/pull/4807/
files#diff-6011fb23e8f8bacb536ab442e57b874cR48
[3] https://github.com/theforeman/foreman/pull/4807/
files#diff-6254f272d0e11d7caaacec9ece0c6669R6

Thanks

--
Marek

-- 
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] Possible to allow public access to finish templates?

2017-12-19 Thread Timo Goebel
Hi Martin,

Check out the foreman_userdata plugin. That might be what you need. It was made 
to make vmware image deployments more fun. The README on github has more detail.

Timo

> On 19. Dec 2017, at 11:48, 'Martin Juhl' via foreman-dev 
>  wrote:
> 
> Hi
> 
> 
> 
> I’m trying to get Linux Image deployments with vmware to work, without SSH…
> 
> Is it possible to allow public access (preferrably IP-based) to the finish 
> templates??? right now I need a login to see them…???
> 
> 
> 
> Thanks
> 
> 
> 
> Martin
> 
> -- 
> 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] Review of all our logrotate configuration

2017-12-19 Thread Lukas Zapletal
Hey,

I spent some time reviewing logrotate scripts because we had some
reports on logrotation when SELinux was preventing it. TL;DR -
resolved the issue, filed temporary fix for our policy and RHEL BZ.

Comments below:

/var/log/foreman/*.log
Works ok, copy and truncate.

/var/log/foreman-proxy/proxy.log
/var/log/foreman-proxy/smart_proxy_dynflow_core.log
Logrotate sends SIGUSR1 which is prevented by SELinux, tracked under
http://projects.theforeman.org/issues/19053

/var/log/puppet/*log
Similar problem but SIGUSR2

For both above, I filed a RHEL BZ
https://bugzilla.redhat.com/show_bug.cgi?id=1527522 and I filed a
temporary PR to solve this via our own policy rule until RHEL 7.6 is
out. https://github.com/theforeman/foreman-selinux/pull/75

Candlepin - had some issues in the past, these are solved now.

Pulp - logs into syslog, no rotation needed.

-- 
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.


[foreman-dev] Possible to allow public access to finish templates?

2017-12-19 Thread 'Martin Juhl' via foreman-dev


Hi


I’m trying to get Linux Image deployments with vmware to work, without SSH…

Is it possible to allow public access (preferrably IP-based) to the finish 
templates??? right now I need a login to see them…???


Thanks


Martin

-- 
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] Pull request github template proposal

2017-12-19 Thread Lukas Zapletal
I created the following proposal:

https://github.com/theforeman/foreman/pull/5099/files

I tried to keep it short and simple. Please comment.

-- 
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.