Fix wsgi_user and wsgi_group in Red Hat platforms
Commit da0cedce6f
assumed that the
user and group for Horizon in Red Hat platforms was 'dashboard', due
to the following lines being present in openstack-dashboard.conf:
WSGIDaemonProcess dashboard
WSGIProcessGroup dashboard
Actually, based on [1], this does not mean that, and the RPM packages
do not create such user, so we should switch that to the apache user.
[1] http://modwsgi.readthedocs.io/en/latest/configuration-directives/WSGIDaemonProcess.html
Change-Id: I52766ac0521951cc8c857e51a61823410585bed5
This commit is contained in:
@@ -17,8 +17,8 @@ class horizon::params {
|
|||||||
$root_url = '/dashboard'
|
$root_url = '/dashboard'
|
||||||
$apache_user = 'apache'
|
$apache_user = 'apache'
|
||||||
$apache_group = 'apache'
|
$apache_group = 'apache'
|
||||||
$wsgi_user = 'dashboard'
|
$wsgi_user = 'apache'
|
||||||
$wsgi_group = 'dashboard'
|
$wsgi_group = 'apache'
|
||||||
$memcache_package = 'python-memcached'
|
$memcache_package = 'python-memcached'
|
||||||
}
|
}
|
||||||
'Debian': {
|
'Debian': {
|
||||||
|
@@ -171,14 +171,8 @@ class horizon::wsgi::apache (
|
|||||||
Package['horizon'] -> Package['httpd']
|
Package['horizon'] -> Package['httpd']
|
||||||
Concat[$::horizon::params::config_file] ~> Service['httpd']
|
Concat[$::horizon::params::config_file] ~> Service['httpd']
|
||||||
|
|
||||||
$unix_user = $::osfamily ? {
|
$unix_user = $::horizon::params::wsgi_user
|
||||||
'RedHat' => $::horizon::params::apache_user,
|
$unix_group = $::horizon::params::wsgi_group
|
||||||
default => $::horizon::params::wsgi_user
|
|
||||||
}
|
|
||||||
$unix_group = $::osfamily ? {
|
|
||||||
'RedHat' => $::horizon::params::apache_group,
|
|
||||||
default => $::horizon::params::wsgi_group,
|
|
||||||
}
|
|
||||||
|
|
||||||
file { $::horizon::params::logdir:
|
file { $::horizon::params::logdir:
|
||||||
ensure => directory,
|
ensure => directory,
|
||||||
|
@@ -200,8 +200,8 @@ describe 'horizon::wsgi::apache' do
|
|||||||
:root_url => '/dashboard',
|
:root_url => '/dashboard',
|
||||||
:apache_user => 'apache',
|
:apache_user => 'apache',
|
||||||
:apache_group => 'apache',
|
:apache_group => 'apache',
|
||||||
:wsgi_user => 'dashboard',
|
:wsgi_user => 'apache',
|
||||||
:wsgi_group => 'dashboard',
|
:wsgi_group => 'apache',
|
||||||
:unix_user => 'apache',
|
:unix_user => 'apache',
|
||||||
:unix_group => 'apache' }
|
:unix_group => 'apache' }
|
||||||
end
|
end
|
||||||
|
Reference in New Issue
Block a user