You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ambari.apache.org by ao...@apache.org on 2014/07/31 18:03:34 UTC
git commit: AMBARI-6699. RE: Nagios UI on Ubuntu cannot find multiple
files resulting in broken markup (aonishuk)
Repository: ambari
Updated Branches:
refs/heads/trunk 09ffe3195 -> 2a268dac5
AMBARI-6699. RE: Nagios UI on Ubuntu cannot find multiple files resulting in broken markup (aonishuk)
Project: http://git-wip-us.apache.org/repos/asf/ambari/repo
Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/2a268dac
Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/2a268dac
Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/2a268dac
Branch: refs/heads/trunk
Commit: 2a268dac5fdfc4dd0da695d434ac622a8d5fbf87
Parents: 09ffe31
Author: Andrew Onishuk <ao...@hortonworks.com>
Authored: Thu Jul 31 19:03:25 2014 +0300
Committer: Andrew Onishuk <ao...@hortonworks.com>
Committed: Thu Jul 31 19:03:25 2014 +0300
----------------------------------------------------------------------
.../stacks/HDP/2.0.6/services/NAGIOS/package/scripts/nagios.py | 5 +++++
.../stacks/HDP/2.0.6/services/NAGIOS/package/scripts/params.py | 5 +++++
.../HDP/2.0.6/services/NAGIOS/package/templates/nagios.conf.j2 | 2 +-
3 files changed, 11 insertions(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/ambari/blob/2a268dac/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/NAGIOS/package/scripts/nagios.py
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/NAGIOS/package/scripts/nagios.py b/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/NAGIOS/package/scripts/nagios.py
index 529acd8..4c88e0d 100644
--- a/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/NAGIOS/package/scripts/nagios.py
+++ b/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/NAGIOS/package/scripts/nagios.py
@@ -81,6 +81,11 @@ def nagios():
group = params.nagios_group,
mode = 0664)
+ if System.get_instance().os_family == "debian":
+ Link(params.debian_stylesheets_desired_location,
+ to = params.debian_stylesheets_real_location
+ )
+
def set_web_permisssions():
import params
http://git-wip-us.apache.org/repos/asf/ambari/blob/2a268dac/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/NAGIOS/package/scripts/params.py
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/NAGIOS/package/scripts/params.py b/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/NAGIOS/package/scripts/params.py
index 504fd4e..21e884f 100644
--- a/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/NAGIOS/package/scripts/params.py
+++ b/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/NAGIOS/package/scripts/params.py
@@ -37,6 +37,11 @@ nagios_obj_dir = format("{conf_dir}/objects")
nagios_var_dir = status_params.nagios_var_dir
nagios_rw_dir = status_params.nagios_rw_dir
+# HACK: Stylesheets for Nagios UI on Ubuntu are in wrong place so we have to do a symlink.
+# In future we can fix this directly in the package.
+debian_stylesheets_real_location = "/etc/nagios3/stylesheets"
+debian_stylesheets_desired_location = "/usr/share/nagios3/htdocs/stylesheets"
+
if System.get_instance().os_family == "debian":
host_template = "generic-host"
plugins_dir = "/usr/lib/nagios/plugins"
http://git-wip-us.apache.org/repos/asf/ambari/blob/2a268dac/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/NAGIOS/package/templates/nagios.conf.j2
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/NAGIOS/package/templates/nagios.conf.j2 b/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/NAGIOS/package/templates/nagios.conf.j2
index d85f423..6fa1ef3 100644
--- a/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/NAGIOS/package/templates/nagios.conf.j2
+++ b/ambari-server/src/main/resources/stacks/HDP/2.0.6/services/NAGIOS/package/templates/nagios.conf.j2
@@ -69,7 +69,7 @@ Alias /nagios3 "{{nagios_web_dir}}"
<Directory "{{nagios_web_dir}}">
# SSLRequireSSL
- Options None
+ Options FollowSymLinks
AllowOverride None
Order allow,deny
Allow from all