From 44638176067df5231bf0be30801e36863391cd1f Mon Sep 17 00:00:00 2001 From: Tim Laszlo Date: Mon, 8 Oct 2012 10:38:02 -0500 Subject: Reporting: Merge new reporting data Move reporting data to a new schema Use south for django migrations Add bcfg2-report-collector daemon Conflicts: doc/development/index.txt doc/server/plugins/connectors/properties.txt doc/server/plugins/generators/packages.txt setup.py src/lib/Bcfg2/Client/Tools/SELinux.py src/lib/Bcfg2/Compat.py src/lib/Bcfg2/Encryption.py src/lib/Bcfg2/Options.py src/lib/Bcfg2/Server/Admin/Init.py src/lib/Bcfg2/Server/Admin/Reports.py src/lib/Bcfg2/Server/BuiltinCore.py src/lib/Bcfg2/Server/Core.py src/lib/Bcfg2/Server/FileMonitor/Inotify.py src/lib/Bcfg2/Server/Plugin/base.py src/lib/Bcfg2/Server/Plugin/interfaces.py src/lib/Bcfg2/Server/Plugins/Cfg/CfgEncryptedGenerator.py src/lib/Bcfg2/Server/Plugins/FileProbes.py src/lib/Bcfg2/Server/Plugins/Ohai.py src/lib/Bcfg2/Server/Plugins/Packages/Collection.py src/lib/Bcfg2/Server/Plugins/Packages/Source.py src/lib/Bcfg2/Server/Plugins/Packages/Yum.py src/lib/Bcfg2/Server/Plugins/Packages/__init__.py src/lib/Bcfg2/Server/Plugins/Probes.py src/lib/Bcfg2/Server/Plugins/Properties.py src/lib/Bcfg2/Server/Reports/backends.py src/lib/Bcfg2/Server/Reports/manage.py src/lib/Bcfg2/Server/Reports/nisauth.py src/lib/Bcfg2/settings.py src/sbin/bcfg2-crypt src/sbin/bcfg2-yum-helper testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestProbes.py testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestSEModules.py --- .../reports/templates/config_items/common.html | 42 ------- .../templates/config_items/entry_status.html | 30 ----- .../reports/templates/config_items/item.html | 130 --------------------- .../reports/templates/config_items/listing.html | 35 ------ 4 files changed, 237 deletions(-) delete mode 100644 src/lib/Bcfg2/Server/Reports/reports/templates/config_items/common.html delete mode 100644 src/lib/Bcfg2/Server/Reports/reports/templates/config_items/entry_status.html delete mode 100644 src/lib/Bcfg2/Server/Reports/reports/templates/config_items/item.html delete mode 100644 src/lib/Bcfg2/Server/Reports/reports/templates/config_items/listing.html (limited to 'src/lib/Bcfg2/Server/Reports/reports/templates/config_items') diff --git a/src/lib/Bcfg2/Server/Reports/reports/templates/config_items/common.html b/src/lib/Bcfg2/Server/Reports/reports/templates/config_items/common.html deleted file mode 100644 index d6ad303fc..000000000 --- a/src/lib/Bcfg2/Server/Reports/reports/templates/config_items/common.html +++ /dev/null @@ -1,42 +0,0 @@ -{% extends "base-timeview.html" %} -{% load bcfg2_tags %} - -{% block title %}Bcfg2 - Common Problems{% endblock %} - -{% block extra_header_info %} -{% endblock%} - -{% block pagebanner %}Common configuration problems{% endblock %} - -{% block content %} -
-
- Showing items with more then {{ threshold }} entries - - -
-
- {% for type_name, type_list in lists %} -
-
-

{{ type_name|capfirst }} entries

-
[–]
-
- {% if type_list %} - - - {% for entry, reason, interaction in type_list %} - - - - - - - {% endfor %} -
TypeNameCountReason
{{ entry.kind }}{{ entry.name }}{{ interaction|length }}{{ reason.short_list|join:"," }}
- {% else %} -

There are currently no inconsistent {{ type_name }} configuration entries.

- {% endif %} -
- {% endfor %} -{% endblock %} diff --git a/src/lib/Bcfg2/Server/Reports/reports/templates/config_items/entry_status.html b/src/lib/Bcfg2/Server/Reports/reports/templates/config_items/entry_status.html deleted file mode 100644 index 5f7579eb9..000000000 --- a/src/lib/Bcfg2/Server/Reports/reports/templates/config_items/entry_status.html +++ /dev/null @@ -1,30 +0,0 @@ -{% extends "base-timeview.html" %} -{% load bcfg2_tags %} - -{% block title %}Bcfg2 - Entry Status{% endblock %} - -{% block extra_header_info %} -{% endblock%} - -{% block pagebanner %}{{ entry.kind }} entry {{ entry.name }} status{% endblock %} - -{% block content %} -{% filter_navigator %} -{% if item_data %} -
- - - {% for ei, inter, reason in item_data %} - - - - - - - {% endfor %} -
NameTimestampStateReason
{{ inter.client.name }}{{ inter.timestamp|date:"Y-m-d\&\n\b\s\p\;H:i"|safe }}{{ ei.get_type_display }}{{ reason.short_list|join:"," }}
-
-{% else %} -

There are currently no hosts with this configuration entry.

-{% endif %} -{% endblock %} diff --git a/src/lib/Bcfg2/Server/Reports/reports/templates/config_items/item.html b/src/lib/Bcfg2/Server/Reports/reports/templates/config_items/item.html deleted file mode 100644 index cadc178a7..000000000 --- a/src/lib/Bcfg2/Server/Reports/reports/templates/config_items/item.html +++ /dev/null @@ -1,130 +0,0 @@ -{% extends "base.html" %} -{% load split %} -{% load syntax_coloring %} - - -{% block title %}Bcfg2 - Element Details{% endblock %} - - -{% block extra_header_info %} - -{% endblock%} - -{% block pagebanner %}Element Details{% endblock %} - -{% block content %} -
-

{{mod_or_bad|capfirst}} {{item.entry.kind}}: {{item.entry.name}}

-
- -
- - {% if isextra %} -

This item exists on the host but is not defined in the configuration.

- {% endif %} - - {% if not item.reason.current_exists %} -
This item does not currently exist on the host but is specified to exist in the configuration.
- {% endif %} - - {% if item.reason.current_owner or item.reason.current_group or item.reason.current_perms or item.reason.current_status or item.reason.current_status or item.reason.current_to or item.reason.current_version %} - - - - {% if item.reason.current_owner %} - - - {% endif %} - {% if item.reason.current_group %} - - - {% endif %} - {% if item.reason.current_perms %} - - - {% endif %} - {% if item.reason.current_status %} - - - {% endif %} - {% if item.reason.current_to %} - - - {% endif %} - {% if item.reason.current_version %} - - - {% endif %} -
Problem TypeExpectedFound
Owner{{item.reason.owner}}{{item.reason.current_owner}}
Group{{item.reason.group}}{{item.reason.current_group}}
Permissions{{item.reason.perms}}{{item.reason.current_perms}}
Status{{item.reason.status}}{{item.reason.current_status}}
Symlink Target{{item.reason.to}}{{item.reason.current_to}}
Package Version{{item.reason.version|cut:"("|cut:")"}}{{item.reason.current_version|cut:"("|cut:")"}}
- {% endif %} - - {% if item.reason.current_diff or item.reason.is_sensitive %} -
-
- {% if item.reason.is_sensitive %} -

File contents unavailable, as they might contain sensitive data.

- {% else %} -

Incorrect file contents

- {% endif %} -
- {% if not item.reason.is_sensitive %} -
- {{ item.reason.current_diff|syntaxhilight }} -
- {% endif %} -
- {% endif %} - - - {% if item.reason.unpruned %} -
-
-

Extra entries found

-
- - {% for unpruned_item in item.reason.unpruned|split %} - - {% endfor %} -
{{ unpruned_item }}
-
- {% endif %} - - -
-
-

Occurences on {{ timestamp|date:"Y-m-d" }}

-
- {% if associated_list %} - - {% for inter in associated_list %} - - - - {% endfor %} -
{{inter.client.name}}{{inter.timestamp}}
- {% else %} -

Missing client list

- {% endif %} -
- -
-{% endblock %} diff --git a/src/lib/Bcfg2/Server/Reports/reports/templates/config_items/listing.html b/src/lib/Bcfg2/Server/Reports/reports/templates/config_items/listing.html deleted file mode 100644 index 0a92e7fc0..000000000 --- a/src/lib/Bcfg2/Server/Reports/reports/templates/config_items/listing.html +++ /dev/null @@ -1,35 +0,0 @@ -{% extends "base-timeview.html" %} -{% load bcfg2_tags %} - -{% block title %}Bcfg2 - Element Listing{% endblock %} - -{% block extra_header_info %} -{% endblock%} - -{% block pagebanner %}{{mod_or_bad|capfirst}} Element Listing{% endblock %} - -{% block content %} -{% filter_navigator %} -{% if item_list %} - {% for type_name, type_data in item_list %} -
-
-

{{ type_name }} — {{ type_data|length }}

-
[–]
-
- - - {% for entry, reason, eis in type_data %} - - - - - - {% endfor %} -
NameCountReason
{{entry.name}}{{ eis|length }}{{ reason.short_list|join:"," }}
-
- {% endfor %} -{% else %} -

There are currently no inconsistent configuration entries.

-{% endif %} -{% endblock %} -- cgit v1.2.3-1-g7c22