Bug 1129408
| Summary: | HA: Systemd unit needs option to be disabled for horizon | ||||||||
|---|---|---|---|---|---|---|---|---|---|
| Product: | Red Hat OpenStack | Reporter: | Jason Guiditta <jguiditt> | ||||||
| Component: | openstack-puppet-modules | Assignee: | Martin Magr <mmagr> | ||||||
| Status: | CLOSED ERRATA | QA Contact: | Leonid Natapov <lnatapov> | ||||||
| Severity: | high | Docs Contact: | |||||||
| Priority: | high | ||||||||
| Version: | 5.0 (RHEL 7) | CC: | aberezin, breeler, ichavero, jguiditt, lnatapov, mburns, mmagr, morazi, rhos-maint, yeylon | ||||||
| Target Milestone: | rc | ||||||||
| Target Release: | 5.0 (RHEL 7) | ||||||||
| Hardware: | Unspecified | ||||||||
| OS: | Unspecified | ||||||||
| Whiteboard: | |||||||||
| Fixed In Version: | openstack-puppet-modules-2014.1-21.4.el6ost | Doc Type: | Bug Fix | ||||||
| Doc Text: | Story Points: | --- | |||||||
| Clone Of: | 1123303 | Environment: | |||||||
| Last Closed: | 2014-09-02 18:10:42 UTC | Type: | Bug | ||||||
| Regression: | --- | Mount Type: | --- | ||||||
| Documentation: | --- | CRM: | |||||||
| Verified Versions: | Category: | --- | |||||||
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||||
| Cloudforms Team: | --- | Target Upstream Version: | |||||||
| Embargoed: | |||||||||
| Bug Depends On: | |||||||||
| Bug Blocks: | 1123303 | ||||||||
| Attachments: |
|
||||||||
|
Comment 4
Jason Guiditta
2014-08-26 21:20:39 UTC
Class ::horizon already contains ::apache definition (via ::horizon::wsgi::apache), so you should remove all ::apache definitions from your manifests. If you need to change default_vhost value to false then I'm afraid we will need to create another patch for that. Or you can try following, it might help:
Class['::apache'] {
default_vhost => false,
}
Ok, so that failed with:
Error: Could not retrieve catalog from remote server: Error 400 on SERVER: Only subclasses can override parameters at 43:/usr/share/openstack-foreman-installer/puppet/modules/quickstack/manifests/horizon.pp on node c1a2.example.com
I also tried 'amending with a collector' as so:
include ::apache
Class <| title == '::apache'|> {
default_vhost => false,
}
and that got me:
Error: Could not retrieve catalog from remote server: Error 400 on SERVER: Resource type class doesn't exist on node c1a2.example.com
What if the opm patch just didn't include the block:
class { '::apache':
service_enable => $enabled,
service_ensure => $service_ensure,
}
in wsgi/apache.pp?
I tried this in my setup, and changed out call to:
class { '::apache' :
default_vhost => false,
service_enable => false,
service_ensure => false,
}
and it got me past the error (though I am not yet sure if it properly disabled the service or not, due to other things that I am testing being in the way of a complete run).. Does that make any sense?
Ok, I tested this on my setup, and it seems to work. httpd.service is disabled as expected, and pacemaker has started the service, also as expected. Created attachment 931660 [details]
Add manage_service feature for horizon
Added changes to RPM patch suggested by Jason Guiditta
I mean for
+ class { '::apache':
+ default_vhost => false,
+ service_enable => $enabled,
+ service_ensure => $service_ensure,
+ }
to go into quick stack, I don't know that it makes sense to set default_vhost = false for everyone, including packstack, but we need it for quick stack.
Created attachment 931662 [details]
Add manage_service feature for horizon [2]
OK, at least visually, this looks right I'm pretty sure that removing definition of class 'apache' gonna break Packstack ... Apparently I was wrong. Seems like class apache::service is used even though class apache is not defined in packstack's horizon.pp manifest. ... can somebody explain how this is possible? :) Ah-hah, there's notification defined, which is pulling the ::apache::service class: File[$::horizon::params::config_file] ~> Service[$::horizon::params::http_service] While this is working, I think this is a fragile state and we should avoid that. What was the reason for removing ::apache definition from ::horizon::wsgi::apache anyway? Yeah, the old version here had include ::apache, which should probably still be there. I think I was unclear when I discussed this with Ivan. Include will work fine, but class declaration makes it so quick stack cannot override the default_vhost param, which we need to do. the patch we added yesterday to the package doesn't break packstack because it has "include ::apache" Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. http://rhn.redhat.com/errata/RHBA-2014-1125.html |