summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--debian/changelog6
-rw-r--r--doc/client/metadata.txt13
-rw-r--r--doc/conf.py4
-rw-r--r--doc/development/caching.txt5
-rw-r--r--doc/development/plugins.txt6
-rw-r--r--doc/exts/xmlschema.py4
-rw-r--r--doc/getting_started/index.txt2
-rw-r--r--doc/releases/1.4.0pre1.txt178
-rw-r--r--doc/server/caching.txt17
-rw-r--r--doc/server/database.txt38
-rw-r--r--doc/server/encryption.txt3
-rw-r--r--doc/server/plugins/generators/cfg.txt1
-rw-r--r--doc/server/plugins/generators/sshbase.txt3
-rw-r--r--doc/server/plugins/index.txt3
-rw-r--r--doc/server/plugins/probes/index.txt3
-rw-r--r--doc/server/plugins/structures/bundler/index.txt12
-rw-r--r--doc/server/xml-common.txt5
-rw-r--r--doc/unsorted/howtos.txt2
-rw-r--r--misc/bcfg2-selinux.spec6
-rw-r--r--misc/bcfg2.spec10
-rw-r--r--osx/Makefile4
-rw-r--r--osx/macports/Portfile2
-rwxr-xr-xredhat/scripts/bcfg2-server.init2
-rw-r--r--solaris-ips/MANIFEST.bcfg2-server.header2
-rw-r--r--solaris-ips/MANIFEST.bcfg2.header2
-rw-r--r--solaris-ips/Makefile2
-rw-r--r--solaris-ips/pkginfo.bcfg22
-rw-r--r--solaris-ips/pkginfo.bcfg2-server2
-rw-r--r--solaris/Makefile2
-rw-r--r--solaris/pkginfo.bcfg22
-rw-r--r--solaris/pkginfo.bcfg2-server2
-rw-r--r--src/lib/Bcfg2/Client/__init__.py4
-rw-r--r--src/lib/Bcfg2/DBSettings.py4
-rwxr-xr-xsrc/lib/Bcfg2/Reporting/Reports.py2
-rw-r--r--src/lib/Bcfg2/Reporting/templates/base.html2
-rw-r--r--src/lib/Bcfg2/Server/Lint/Bundler.py4
-rw-r--r--src/lib/Bcfg2/Server/Plugin/helpers.py8
-rw-r--r--src/lib/Bcfg2/Server/Plugins/Metadata.py29
-rw-r--r--src/lib/Bcfg2/Server/Plugins/Reporting.py6
-rw-r--r--src/lib/Bcfg2/version.py2
-rwxr-xr-xtools/export.py6
41 files changed, 319 insertions, 93 deletions
diff --git a/debian/changelog b/debian/changelog
index b6d7644b9..e30fba546 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,9 @@
+bcfg2 (1.4.0pre1-0.0) unstable; urgency=low
+
+ * New upstream release
+
+ -- Sol Jerome <sol.jerome@gmail.com> Mon, 16 Jun 2014 09:36:13 -0500
+
bcfg2 (1.3.4-0.0) unstable; urgency=low
* New upstream release
diff --git a/doc/client/metadata.txt b/doc/client/metadata.txt
index 27870ba9a..0dec5e3a7 100644
--- a/doc/client/metadata.txt
+++ b/doc/client/metadata.txt
@@ -1,4 +1,5 @@
.. -*- mode: rst -*-
+.. vim: ft=rst
.. _client-metadata:
@@ -24,12 +25,12 @@ interaction:
This construction process spans several server plugins. The
:ref:`server-plugins-grouping-metadata` is responsible for
initial instance creation, including the client hostname,
-profile, and basic group memberships. After this initial creation,
-Connector plugins (such as :ref:`server-plugins-probes-index` or
-:ref:`server-plugins-connectors-properties`) can add additional group
-memberships for clients. These memberships are merged into the instance;
-that is, the new group memberships are treated as if they were included
-in groups.xml. If any of these groups are defined in groups.xml,
+profile, and basic group memberships. After this initial
+creation, Connector plugins (such as :ref:`server-plugins-probes`
+or :ref:`server-plugins-connectors-properties`) can add additional
+group memberships for clients. These memberships are merged into the
+instance; that is, the new group memberships are treated as if they were
+included in groups.xml. If any of these groups are defined in groups.xml,
then groups included there are included in the ClientMetadata instance
group list. At the end of this process, the ClientMetadata instance has
its complete set of group memberships. At this point, each connector
diff --git a/doc/conf.py b/doc/conf.py
index 1b19d92c7..1da6b3b01 100644
--- a/doc/conf.py
+++ b/doc/conf.py
@@ -64,9 +64,9 @@ else:
# built documents.
#
# The short X.Y version.
-version = '1.3'
+version = '1.4'
# The full version, including alpha/beta/rc tags.
-release = '1.3.4'
+release = '1.4.0'
# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.
diff --git a/doc/development/caching.txt b/doc/development/caching.txt
index 47d627278..83ec0290f 100644
--- a/doc/development/caching.txt
+++ b/doc/development/caching.txt
@@ -1,4 +1,5 @@
.. -*- mode: rst -*-
+.. vim: ft=rst
.. _development-cache:
@@ -44,10 +45,10 @@ Currently known caches are:
| Metadata | Hostname | :class:`ClientMetadata | The :ref:`Metadata cache <server-caching>` |
| | | <Bcfg2.Server.Plugins.Metadata.ClientMetadata>` | |
+-------------+---------------------------------------+-------------------------------------------------+------------------------------------------------------+
-| Probes, | Hostname | ``list`` of group names | Groups set by :ref:`server-plugins-probes-index` |
+| Probes, | Hostname | ``list`` of group names | Groups set by :ref:`server-plugins-probes` |
| probegroups | | | |
+-------------+---------------------------------------+-------------------------------------------------+------------------------------------------------------+
-| Probes, | Hostname | ``dict`` of ``<probe name>``: | Other data set by :ref:`server-plugins-probes-index` |
+| Probes, | Hostname | ``dict`` of ``<probe name>``: | Other data set by :ref:`server-plugins-probes` |
| probedata | | :class:`ProbeData | |
| | | <Bcfg2.Server.Plugins.Probes.ProbeData>` | |
+-------------+---------------------------------------+-------------------------------------------------+------------------------------------------------------+
diff --git a/doc/development/plugins.txt b/doc/development/plugins.txt
index e4f16b84d..5993c4e29 100644
--- a/doc/development/plugins.txt
+++ b/doc/development/plugins.txt
@@ -1,4 +1,5 @@
.. -*- mode: rst -*-
+.. vim: ft=rst
.. _development-plugins:
@@ -147,9 +148,8 @@ For examples, see:
* :func:`Bcfg2.Server.Plugins.Probes.ReceiveData` takes a copy of the
groups that have been assigned to a client by
- :ref:`server-plugins-probes-index`, and if that data changes when
- new probe data is received, it invalidates the cache for that
- client.
+ :ref:`server-plugins-probes`, and if that data changes when new probe
+ data is received, it invalidates the cache for that client.
* :func:`Bcfg2.Server.Plugins.GroupPatterns.Index` expires the entire
cache whenever a FAM event is received for the
:ref:`server-plugins-grouping-grouppatterns` config file.
diff --git a/doc/exts/xmlschema.py b/doc/exts/xmlschema.py
index c26aed81e..89104c2a6 100644
--- a/doc/exts/xmlschema.py
+++ b/doc/exts/xmlschema.py
@@ -784,7 +784,7 @@ class XMLDomain(Domain):
def clear_doc(self, docname):
to_del = []
for dtype in self.types.keys():
- for key, (doc, _) in self.data[dtype].iteritems():
+ for key, (doc, _) in self.data[dtype].items():
if doc == docname:
to_del.append((dtype, key))
for dtype, key in to_del:
@@ -803,7 +803,7 @@ class XMLDomain(Domain):
def get_objects(self):
for dtype in self.types.keys():
- for name, (docname, tgtid) in self.data[dtype].iteritems():
+ for name, (docname, tgtid) in self.data[dtype].items():
yield (name, name, dtype, docname, tgtid,
self.object_types[dtype].attrs['searchprio'])
diff --git a/doc/getting_started/index.txt b/doc/getting_started/index.txt
index 9b69bf65a..62e804553 100644
--- a/doc/getting_started/index.txt
+++ b/doc/getting_started/index.txt
@@ -223,7 +223,7 @@ you will find that we now have a correct entry::
Done! Now we just have 242 (or more) entries to take care of!
-:ref:`server-plugins-structures-bundler-index` is a
+:ref:`server-plugins-structures-bundler` is a
relatively easy directory to populate. You can find many
samples of Bundles in the :ref:`Bundler Example Repository
<server-plugins-structures-bundler-index-examples>`, many of which can
diff --git a/doc/releases/1.4.0pre1.txt b/doc/releases/1.4.0pre1.txt
new file mode 100644
index 000000000..1f92f4665
--- /dev/null
+++ b/doc/releases/1.4.0pre1.txt
@@ -0,0 +1,178 @@
+.. -*- mode: rst -*-
+.. vim: ft=rst
+
+.. _releases-1.4.0pre1:
+
+1.4.0pre1
+=========
+
+The first prerelease for Bcfg2 1.4.0 is now available at:
+
+ ftp://ftp.mcs.anl.gov/pub/bcfg
+
+Bcfg2 1.4.0pre1 is a prerelease, and contains many new features,
+including some that are backwards-incompatible with Bcfg2 1.3.x and
+earlier. Please read the release notes thoroughly. This is a prerelease
+and as such is not likely suitable for general production deployment.
+That said, please help us test the release in non- and preproduction
+environments.
+
+backwards-incompatible user-facing changes
+------------------------------------------
+
+* Completely rewrote option parser
+
+ Many single character options now have long equivalents. Some
+ subcommand interfaces (``bcfg2-info``, ``bcfg2-admin``) have been
+ reorganized to some degree. ``bcfg2-reports`` syntax is completely
+ different.
+
+* Added new :ref:`server-plugins-misc-acl` plugin
+
+ Default ACLs only allow clients to perform bcfg2 client runs, and only
+ permit `bcfg2-admin xcmd` calls from localhost. If you want to change
+ this, you must enable the ACL plugin and configure your own ACLs.
+
+* Added genshi requirement for the server
+
+* :ref:`server-plugins-generators-decisions`
+
+ * Switch plugin to use StructFile instead of host- or group-specific XML
+ files (this allows a single e.g. whitelist.xml file with <Group> tags)
+
+ You can convert your existing decisions using
+ ``tools/upgrade/1.4/migrate_decisions.py``.
+
+
+deprecated features (will be removed in a future release, likely 1.5)
+---------------------------------------------------------------------
+
+* :ref:`server-plugins-structures-bundler`
+
+ * Deprecated use of an explicit name attribute
+ * Deprecated :ref:`.genshi bundles
+ <server-plugins-structures-bundler-index-genshi-templates>` (use
+ .xml bundles and specify the genshi namespace instead)
+
+* SSLCA
+
+ * Deprecated plugin
+ * SSLCA functionality has been added to the Cfg plugin:
+ see :ref:`server-plugins-generators-cfg-ssl-certificates`
+
+deprecated plugins and features which have been removed
+-------------------------------------------------------
+
+Plugins
+^^^^^^^
+
+* PostInstall
+* TGenshi
+* TCheetah
+* Account
+* Hostbase
+* Snapshots
+* Statistics
+* Editor
+* Base
+
+Client tools
+^^^^^^^^^^^^
+
+* RPMng
+* YUM24
+* YUMng
+
+Other features
+^^^^^^^^^^^^^^
+
+* FAM filemonitor
+* Removed mode="inherit" support
+* Removed support for .cat/.diff files
+* Removed support for info/:info files
+* Removed "magic" groups (for the Packages plugin)
+
+other fixes and new features
+----------------------------
+
+* Added :ref:`inter-bundle dependencies
+ <server-plugins-structures-bundler-index-dependencies>`
+* Added support for :ref:`independent bundles
+ <server-plugins-structures-bundler-index-disabling-magic>` (replaces
+ the functionality of Base):
+* Added support for wildcard XIncludes
+* Add Solaris 11 IPS Package support
+* Add bcfg2-report-collector init script to debian package
+* Git VCS plugin enhancements
+* Removed deprecated plugins
+
+* :ref:`server-plugins-structures-bundler`
+
+ * Deprecated use of an explicit name attribute
+ * Deprecated .genshi bundles
+ * Added path globbing
+
+* :ref:`server-plugins-grouping-metadata`
+
+ * Allow setting global default authentication type
+
+* :ref:`server-plugins-generators-packages`
+
+ * Add yum group support to internal resolver
+ * Change location of plugin-generated APT sources
+ * Add new Pkgng plugin
+ * Add ability for per-package recommended flag override
+
+* :ref:`server-plugins-statistics-reporting`
+
+ * Add support for POSIX user/group entries
+ * Add support for Django > 1.4
+ * Add support for separate reporting database
+
+* Added option to periodically dump performance stats to logs
+* Added option to force server to wait until all FAM events are
+ processed
+
+* :ref:`server-plugins-generators-sshbase`
+
+ * Add support for IPv6 addresses in known_hosts file
+ * Add support for :ref:`encryption of generated ssh keys
+ <server-plugins-generators-sshbase-encryption>`
+
+* APT
+
+ * Allow specification of deb-src lines (resolves
+ http://trac.mcs.anl.gov/projects/bcfg2/ticket/1148)
+
+* SSLCA
+
+ * Rewrote SSLCA as Cfg handler
+
+ Existing SSLCA installations will need to migrate to the new format
+ using ``tools/upgrade/1.4/migrate_sslca.py``.
+
+* :ref:`server-plugins-generators-nagiosgen`
+
+ * Migrate configuration to conf.d
+
+* :ref:`server-plugins-probes`
+
+ * Rewritten to improve caching
+ * Add probes.allowed_groups option to restrict group assignments:
+ see :ref:`server-plugins-probes-dynamic-groups`
+
+
+Thanks
+------
+
+Special thanks to the following contributors for this release
+
+ * Alexander Sulfrain
+ * Chris Brinker
+ * Duncan Hutty
+ * Jason Kincl
+ * John Morris
+ * Matt Schwager
+ * Michael Fenn
+ * Stéphane Graber
+ * Tim Laszlo
diff --git a/doc/server/caching.txt b/doc/server/caching.txt
index 32be684db..3557bf0f3 100644
--- a/doc/server/caching.txt
+++ b/doc/server/caching.txt
@@ -1,4 +1,5 @@
.. -*- mode: rst -*-
+.. vim: ft=rst
.. _server-caching:
@@ -42,15 +43,15 @@ descending order of reliability. That is, odds are higher that
biggest speed boost. ``off`` will never result in stale data, but it
gives no speed boost.
-In addition to the :ref:`server-plugins-grouping-metadata` plugin,
-Bcfg2 includes three plugins that can set additional groups, and thus
-may affect the caching behavior. They are
-:ref:`server-plugins-grouping-grouppatterns`,
-:ref:`server-plugins-probes-index`, and
+In addition to the :ref:`server-plugins-grouping-metadata`
+plugin, Bcfg2 includes three plugins that can set additional
+groups, and thus may affect the caching behavior. They
+are :ref:`server-plugins-grouping-grouppatterns`,
+:ref:`server-plugins-probes`, and
:ref:`server-plugins-connectors-puppetenc`. All of those plugins
-**except** for PuppetENC fully support all caching levels. PuppetENC
-is incompatible with ``aggressive``, and may result in some stale data
-with ``cautious``.
+**except** for PuppetENC fully support all caching levels. PuppetENC is
+incompatible with ``aggressive``, and may result in some stale data with
+``cautious``.
If you are not using the PuppetENC plugin, and do not have any custom
plugins that provide additional groups, then all four modes should be
diff --git a/doc/server/database.txt b/doc/server/database.txt
index fdb3ab04c..986914171 100644
--- a/doc/server/database.txt
+++ b/doc/server/database.txt
@@ -10,20 +10,19 @@ Global Database Settings
.. versionadded:: 1.3.0
Several Bcfg2 plugins, including
-:ref:`server-plugins-grouping-metadata`,
-:ref:`server-plugins-probes-index`, and
-:ref:`server-plugins-statistics-reporting`, can connect use a
-relational database to store data. They use the global database
-settings in ``bcfg2.conf``, described in this document, to connect.
+:ref:`server-plugins-grouping-metadata`, :ref:`server-plugins-probes`, and
+:ref:`server-plugins-statistics-reporting`, can connect use a relational
+database to store data. They use the global database settings in
+``bcfg2.conf``, described in this document, to connect.
.. note::
Although SQLite is supported as a database, it may cause
- significant thread contention (and a performance penalty) if you
- use SQLite with :ref:`server-plugins-grouping-metadata` or
- :ref:`server-plugins-probes-index`. If you are using the
- database-backed features of either of those plugins, it's
- recommended that you use a higher performance database backend.
+ significant thread contention (and a performance penalty) if
+ you use SQLite with :ref:`server-plugins-grouping-metadata` or
+ :ref:`server-plugins-probes`. If you are using the database-backed
+ features of either of those plugins, it's recommended that you use
+ a higher performance database backend.
Separate Reporting Database
@@ -31,15 +30,16 @@ Separate Reporting Database
.. versionadded:: 1.4.0
-Bcfg2 supports storing the data generated by the
-:ref:`server-plugins-statistics-reporting` in a separate database
-from the data generated by the other plugins (e.g.
-:ref:`server-plugins-grouping-metadata` and
-:ref:`server-plugins-probes-index`). To activate this support, set
-the ``reporting_engine``, ``reporting_name``, ``reporting_user``, etc.
-options in the ``[database]`` section of the config file. The valid values
-for the ``reporting_*`` options are the same as for the standard database
-options. See :ref:`server-database-configuration-options` for a full listing.
+Bcfg2 supports storing the data generated by the
+:ref:`server-plugins-statistics-reporting` in a separate
+database from the data generated by the other plugins (e.g.
+:ref:`server-plugins-grouping-metadata` and :ref:`server-plugins-probes`).
+To activate this support, set the ``reporting_engine``,
+``reporting_name``, ``reporting_user``, etc. options in the
+``[database]`` section of the config file. The valid values for the
+``reporting_*`` options are the same as for the standard database
+options. See :ref:`server-database-configuration-options` for a full
+listing.
.. _server-database-configuration-options:
diff --git a/doc/server/encryption.txt b/doc/server/encryption.txt
index b657deb8c..db5e2ae29 100644
--- a/doc/server/encryption.txt
+++ b/doc/server/encryption.txt
@@ -1,4 +1,5 @@
.. -*- mode: rst -*-
+.. vim: ft=rst
.. _server-encryption:
@@ -54,7 +55,7 @@ In general, Properties encryption is preferred for a few reasons:
Other types of data that can be encrypted are:
* Text content of Path tags in
- :ref:`server-plugins-structures-bundler-index`
+ :ref:`server-plugins-structures-bundler`
* Passphrases in XML description files for generated
:ref:`server-plugins-generators-cfg-sshkeys`
diff --git a/doc/server/plugins/generators/cfg.txt b/doc/server/plugins/generators/cfg.txt
index 7a404c824..9ebbd2666 100644
--- a/doc/server/plugins/generators/cfg.txt
+++ b/doc/server/plugins/generators/cfg.txt
@@ -1,4 +1,5 @@
.. -*- mode: rst -*-
+.. vim: ft=rst
.. _server-plugins-generators-cfg:
diff --git a/doc/server/plugins/generators/sshbase.txt b/doc/server/plugins/generators/sshbase.txt
index 4578d5810..540cc1e06 100644
--- a/doc/server/plugins/generators/sshbase.txt
+++ b/doc/server/plugins/generators/sshbase.txt
@@ -162,6 +162,9 @@ in order to permit :ref:`pulling with bcfg2-admin
<server-admin-pull>`. You should almost certainly set ``sensitive``
to "true" in ``info.xml``.
+
+.. _server-plugins-generators-sshbase-encryption:
+
Encryption
==========
diff --git a/doc/server/plugins/index.txt b/doc/server/plugins/index.txt
index f3d6daa73..b39be0786 100644
--- a/doc/server/plugins/index.txt
+++ b/doc/server/plugins/index.txt
@@ -1,4 +1,5 @@
.. -*- mode: rst -*-
+.. vim: ft=rst
.. _server-plugins-index:
@@ -13,7 +14,7 @@ perform one of several tasks:
#. Generating configuration entry contents for clients
#. Probing client-side state (like hardware inventory, etc)
-- the generic client probing mechanism is described at
- :ref:`server-plugins-probes-index`.
+ :ref:`server-plugins-probes`.
#. Automating administrative tasks
(e.g. :ref:`server-plugins-generators-sshbase` which automates ssh
key management)
diff --git a/doc/server/plugins/probes/index.txt b/doc/server/plugins/probes/index.txt
index 2e23c31d5..091c85e63 100644
--- a/doc/server/plugins/probes/index.txt
+++ b/doc/server/plugins/probes/index.txt
@@ -1,6 +1,7 @@
.. -*- mode: rst -*-
+.. vim: ft=rst
-.. _server-plugins-probes-index:
+.. _server-plugins-probes:
======
Probes
diff --git a/doc/server/plugins/structures/bundler/index.txt b/doc/server/plugins/structures/bundler/index.txt
index 0b6b8eb50..31faeaf17 100644
--- a/doc/server/plugins/structures/bundler/index.txt
+++ b/doc/server/plugins/structures/bundler/index.txt
@@ -1,6 +1,7 @@
.. -*- mode: rst -*-
+.. vim: ft=rst
-.. _server-plugins-structures-bundler-index:
+.. _server-plugins-structures-bundler:
=======
Bundler
@@ -91,6 +92,9 @@ split these entries into two bundles. See
:ref:`server-plugins-structures-bundler-bcfg2-server` for an example
of this.
+
+.. _server-plugins-structures-bundler-index-disabling-magic:
+
Disabling Magic
---------------
@@ -111,6 +115,9 @@ entries in independent bundles are only executed if ``when="always"``.
(I.e., an Action entry in an independent bundle with
``when="modified"`` is useless.)
+
+.. _server-plugins-structures-bundler-index-genshi-templates:
+
Genshi templates
================
@@ -138,6 +145,9 @@ entries in the bundle.
See :ref:`bcfg2-info <server-bcfg2-info>` for more details.
+
+.. _server-plugins-structures-bundler-index-dependencies:
+
Dependencies
============
diff --git a/doc/server/xml-common.txt b/doc/server/xml-common.txt
index ab558c2cb..5302a59e4 100644
--- a/doc/server/xml-common.txt
+++ b/doc/server/xml-common.txt
@@ -1,4 +1,5 @@
.. -*- mode: rst -*-
+.. vim: ft=rst
.. _xml-features:
@@ -76,7 +77,7 @@ Or, more compactly:
Manage the abstract service "bar"
As an example, consider the following :ref:`bundle
-<server-plugins-structures-bundler-index>`:
+<server-plugins-structures-bundler>`:
.. code-block:: xml
@@ -309,7 +310,7 @@ Feature Matrix
| <server-plugins-misc-acl>` | | | | |
+---------------------------------------------------+--------------+--------+------------+------------+
| :ref:`Bundler | Yes | Yes | Yes | Yes |
-| <server-plugins-structures-bundler-index>` | | | | |
+| <server-plugins-structures-bundler>` | | | | |
+---------------------------------------------------+--------------+--------+------------+------------+
| :ref:`info.xml <server-info>` | Yes [#f1]_ | Yes | Yes | Yes |
+---------------------------------------------------+--------------+--------+------------+------------+
diff --git a/doc/unsorted/howtos.txt b/doc/unsorted/howtos.txt
index cef64a394..81b38e54d 100644
--- a/doc/unsorted/howtos.txt
+++ b/doc/unsorted/howtos.txt
@@ -12,7 +12,7 @@ Here are several howtos that describe different aspects of Bcfg2 deployment
* AnnotatedExamples - a description of basic Bcfg2 specification operations
* BuildingDebianPackages - How to build debian packages
* :ref:`appendix-guides-gentoo` - Issues specific to running Bcfg2 on Gentoo
-* :ref:`server-plugins-probes-index` - How to use Probes to gather information from a client machine.
+* :ref:`server-plugins-probes` - How to use Probes to gather information from a client machine.
* :ref:`client-tools-actions` - How to use Actions
* :ref:`server-plugins-probes-dynamic-groups` - Using dynamic groups
* :ref:`client-modes-paranoid` - How to run an update in paranoid mode
diff --git a/misc/bcfg2-selinux.spec b/misc/bcfg2-selinux.spec
index d33953e08..e3701bbdd 100644
--- a/misc/bcfg2-selinux.spec
+++ b/misc/bcfg2-selinux.spec
@@ -12,11 +12,11 @@
#
# Don't forget to change the Release: tag below to something like 0.1
#%%global _rc 1
-#%%global _pre 2
+%global _pre pre1
%global _pre_rc %{?_pre:.pre%{_pre}}%{?_rc:.rc%{_rc}}
Name: bcfg2-selinux
-Version: 1.3.4
+Version: 1.4.0
Release: 1%{?_pre_rc}%{?dist}
Summary: Bcfg2 Client and Server SELinux policy
@@ -33,7 +33,7 @@ Conflicts: selinux-policy = 3.11.1
License: BSD
URL: http://bcfg2.org
Source0: ftp://ftp.mcs.anl.gov/pub/bcfg/%{name}-%{version}%{?_pre_rc}.tar.gz
-BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
+BuildRoot: %{_tmppath}/%{name}-%{version}%{?_pre_rc}-%{release}-root-%(%{__id_u} -n)
BuildArch: noarch
BuildRequires: checkpolicy, selinux-policy-devel, hardlink
diff --git a/misc/bcfg2.spec b/misc/bcfg2.spec
index 3539b0dec..357afed4e 100644
--- a/misc/bcfg2.spec
+++ b/misc/bcfg2.spec
@@ -19,7 +19,7 @@
#
# Don't forget to change the Release: tag below to something like 0.1
#%%global _rc 1
-#%%global _pre 2
+%global _pre pre1
%global _nightly 1
%global _date %(date +%Y%m%d)
%global _pre_rc %{?_pre:pre%{_pre}}%{?_rc:rc%{_rc}}
@@ -48,7 +48,7 @@ Source0: ftp://ftp.mcs.anl.gov/pub/bcfg/%{name}-%{version}%{?_pre_rc}.t
Source1: http://www.w3.org/2001/XMLSchema.xsd
%if %{?rhel}%{!?rhel:10} <= 5 || 0%{?suse_version}
# EL5 and OpenSUSE require the BuildRoot tag
-BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
+BuildRoot: %{_tmppath}/%{name}-%{version}%{?_pre_rc}-%{release}-root-%(%{__id_u} -n)
%endif
BuildArch: noarch
@@ -258,10 +258,8 @@ Group: System Environment/Daemons
Requires: bcfg2 = %{version}-%{release}
Requires: bcfg2-server = %{version}-%{release}
-# cherrypy 3.3 actually doesn't exist yet, but 3.2 has bugs that
-# prevent it from working:
-# https://bitbucket.org/cherrypy/cherrypy/issue/1154/assertionerror-in-recv-when-ssl-is-enabled
-Requires: python-cherrypy > 3.3
+# https://bitbucket.org/cherrypy/cherrypy/issue/1068/file-upload-crashes-when-using-https
+Requires: python-cherrypy >= 3.2.6
%description server-cherrypy
Bcfg2 helps system administrators produce a consistent, reproducible,
diff --git a/osx/Makefile b/osx/Makefile
index 3cc92f9dc..174eb53c8 100644
--- a/osx/Makefile
+++ b/osx/Makefile
@@ -28,9 +28,9 @@ SITELIBDIR = /Library/Python/${PYVERSION}/site-packages
# an Info.plist file for packagemaker to look at for package creation
# and substitute the version strings. Major/Minor versions can only be
# integers (e.g. "1" and "00" for bcfg2 version 1.0.0.
-BCFGVER = 1.3.4
+BCFGVER = 1.4.0pre1
MAJOR = 1
-MINOR = 34
+MINOR = 40
default: clean client
diff --git a/osx/macports/Portfile b/osx/macports/Portfile
index 28e345c3b..05ce40bf0 100644
--- a/osx/macports/Portfile
+++ b/osx/macports/Portfile
@@ -5,7 +5,7 @@ PortSystem 1.0
PortGroup python26 1.0
name bcfg2
-version 1.3.4
+version 1.4.0pre1
categories sysutils python
maintainers gmail.com:sol.jerome
license BSD
diff --git a/redhat/scripts/bcfg2-server.init b/redhat/scripts/bcfg2-server.init
index 7fd1bd906..f14938a16 100755
--- a/redhat/scripts/bcfg2-server.init
+++ b/redhat/scripts/bcfg2-server.init
@@ -27,7 +27,7 @@ PATH=/sbin:/bin:/usr/bin:/usr/sbin
test -f /etc/sysconfig/$prog && . /etc/sysconfig/$prog
if [ "$BCFG2_SERVER_ENABLED" -eq 0 ] ; then
- failure $"bcfg2-server is disabled - see /etc/sysconfig/bcfg2-server"
+ failure $"bcfg2-server is disabled - see /etc/sysconfig/$prog"
echo
exit 0
fi
diff --git a/solaris-ips/MANIFEST.bcfg2-server.header b/solaris-ips/MANIFEST.bcfg2-server.header
index b72adc486..5a837b5c7 100644
--- a/solaris-ips/MANIFEST.bcfg2-server.header
+++ b/solaris-ips/MANIFEST.bcfg2-server.header
@@ -1,4 +1,4 @@
license ../../LICENSE license=simplified_bsd
set name=description value="Configuration management server"
set name=pkg.summary value="Configuration management server"
-set name=pkg.fmri value="pkg://bcfg2/bcfg2-server@1.3.4"
+set name=pkg.fmri value="pkg://bcfg2/bcfg2-server@1.4.0pre1"
diff --git a/solaris-ips/MANIFEST.bcfg2.header b/solaris-ips/MANIFEST.bcfg2.header
index 19fc567fe..5fd5c0c5d 100644
--- a/solaris-ips/MANIFEST.bcfg2.header
+++ b/solaris-ips/MANIFEST.bcfg2.header
@@ -1,5 +1,5 @@
license ../../LICENSE license=simplified_bsd
set name=description value="Configuration management client"
set name=pkg.summary value="Configuration management client"
-set name=pkg.fmri value="pkg://bcfg2/bcfg2@1.3.4"
+set name=pkg.fmri value="pkg://bcfg2/bcfg2@1.4.0pre1"
file usr/bin/bcfg2 group=bin mode=0755 owner=root path=usr/bin/bcfg2
diff --git a/solaris-ips/Makefile b/solaris-ips/Makefile
index 7d59e2456..63a1ac61e 100644
--- a/solaris-ips/Makefile
+++ b/solaris-ips/Makefile
@@ -1,6 +1,6 @@
#!/usr/bin/gmake
-VERS=1.3.4-1
+VERS=1.4.0pre1-1
PYVERSION := $(shell python -c "import sys; print sys.version[0:3]")
default: clean package
diff --git a/solaris-ips/pkginfo.bcfg2 b/solaris-ips/pkginfo.bcfg2
index 80f26fc0a..236009c8f 100644
--- a/solaris-ips/pkginfo.bcfg2
+++ b/solaris-ips/pkginfo.bcfg2
@@ -1,7 +1,7 @@
PKG="SCbcfg2"
NAME="bcfg2"
ARCH="sparc"
-VERSION="1.3.4"
+VERSION="1.4.0pre1"
CATEGORY="application"
VENDOR="Argonne National Labratory"
EMAIL="bcfg-dev@mcs.anl.gov"
diff --git a/solaris-ips/pkginfo.bcfg2-server b/solaris-ips/pkginfo.bcfg2-server
index 88d0e6dff..af1ab36fc 100644
--- a/solaris-ips/pkginfo.bcfg2-server
+++ b/solaris-ips/pkginfo.bcfg2-server
@@ -1,7 +1,7 @@
PKG="SCbcfg2-server"
NAME="bcfg2-server"
ARCH="sparc"
-VERSION="1.3.4"
+VERSION="1.4.0pre1"
CATEGORY="application"
VENDOR="Argonne National Labratory"
EMAIL="bcfg-dev@mcs.anl.gov"
diff --git a/solaris/Makefile b/solaris/Makefile
index 995253ea8..cdf61d8f7 100644
--- a/solaris/Makefile
+++ b/solaris/Makefile
@@ -1,7 +1,7 @@
#!/usr/sfw/bin/gmake
PYTHON="/usr/local/bin/python"
-VERS=1.3.4-1
+VERS=1.4.0pre1-1
PYVERSION := $(shell $(PYTHON) -c "import sys; print sys.version[0:3]")
default: clean package
diff --git a/solaris/pkginfo.bcfg2 b/solaris/pkginfo.bcfg2
index 80f26fc0a..236009c8f 100644
--- a/solaris/pkginfo.bcfg2
+++ b/solaris/pkginfo.bcfg2
@@ -1,7 +1,7 @@
PKG="SCbcfg2"
NAME="bcfg2"
ARCH="sparc"
-VERSION="1.3.4"
+VERSION="1.4.0pre1"
CATEGORY="application"
VENDOR="Argonne National Labratory"
EMAIL="bcfg-dev@mcs.anl.gov"
diff --git a/solaris/pkginfo.bcfg2-server b/solaris/pkginfo.bcfg2-server
index 88d0e6dff..af1ab36fc 100644
--- a/solaris/pkginfo.bcfg2-server
+++ b/solaris/pkginfo.bcfg2-server
@@ -1,7 +1,7 @@
PKG="SCbcfg2-server"
NAME="bcfg2-server"
ARCH="sparc"
-VERSION="1.3.4"
+VERSION="1.4.0pre1"
CATEGORY="application"
VENDOR="Argonne National Labratory"
EMAIL="bcfg-dev@mcs.anl.gov"
diff --git a/src/lib/Bcfg2/Client/__init__.py b/src/lib/Bcfg2/Client/__init__.py
index 3da80067d..f1b32d929 100644
--- a/src/lib/Bcfg2/Client/__init__.py
+++ b/src/lib/Bcfg2/Client/__init__.py
@@ -69,8 +69,8 @@ def prompt(msg):
except UnicodeEncodeError:
ans = input(msg.encode('utf-8'))
return ans in ['y', 'Y']
- except EOFError:
- # handle ^C on rhel-based platforms
+ except (EOFError, KeyboardInterrupt):
+ # handle ^C
raise SystemExit(1)
except:
print("Error while reading input: %s" % sys.exc_info()[1])
diff --git a/src/lib/Bcfg2/DBSettings.py b/src/lib/Bcfg2/DBSettings.py
index c5b78ed0b..12dba7fba 100644
--- a/src/lib/Bcfg2/DBSettings.py
+++ b/src/lib/Bcfg2/DBSettings.py
@@ -26,8 +26,8 @@ settings = dict( # pylint: disable=C0103
DEBUG=False,
ALLOWED_HOSTS=['*'],
MEDIA_URL='/site_media/',
- MANAGERS=(('Root', 'root')),
- ADMINS=(('Root', 'root')),
+ MANAGERS=(('Root', 'root'),),
+ ADMINS=(('Root', 'root'),),
# Language code for this installation. All choices can be found
# here:
# http://www.w3.org/TR/REC-html40/struct/dirlang.html#langcodes
diff --git a/src/lib/Bcfg2/Reporting/Reports.py b/src/lib/Bcfg2/Reporting/Reports.py
index 35c09a7e1..219d74584 100755
--- a/src/lib/Bcfg2/Reporting/Reports.py
+++ b/src/lib/Bcfg2/Reporting/Reports.py
@@ -43,6 +43,8 @@ def print_fields(fields, client, fmt, extra=None):
fdata.append(client.current_interaction.extra_count)
elif field == 'bad':
fdata.append((client.current_interaction.bad_count))
+ elif field == 'stale':
+ fdata.append(client.current_interaction.isstale())
else:
try:
fdata.append(getattr(client, field))
diff --git a/src/lib/Bcfg2/Reporting/templates/base.html b/src/lib/Bcfg2/Reporting/templates/base.html
index ef6799c2b..8b197231c 100644
--- a/src/lib/Bcfg2/Reporting/templates/base.html
+++ b/src/lib/Bcfg2/Reporting/templates/base.html
@@ -93,7 +93,7 @@ This is needed for Django versions less than 1.5
<div style='clear:both'></div>
</div><!-- document -->
<div id="footer">
- <span>Bcfg2 Version 1.3.4</span>
+ <span>Bcfg2 Version 1.4.0pre1</span>
</div>
<div id="calendar_div" style='position:absolute; visibility:hidden; background-color:white; layer-background-color:white;'></div>
diff --git a/src/lib/Bcfg2/Server/Lint/Bundler.py b/src/lib/Bcfg2/Server/Lint/Bundler.py
index 0caf4d7ed..aee15cb5d 100644
--- a/src/lib/Bcfg2/Server/Lint/Bundler.py
+++ b/src/lib/Bcfg2/Server/Lint/Bundler.py
@@ -1,12 +1,12 @@
""" ``bcfg2-lint`` plugin for :ref:`Bundler
-<server-plugins-structures-bundler-index>` """
+<server-plugins-structures-bundler>` """
from Bcfg2.Server.Lint import ServerPlugin
class Bundler(ServerPlugin):
""" Perform various :ref:`Bundler
- <server-plugins-structures-bundler-index>` checks. """
+ <server-plugins-structures-bundler>` checks. """
def Run(self):
self.missing_bundles()
diff --git a/src/lib/Bcfg2/Server/Plugin/helpers.py b/src/lib/Bcfg2/Server/Plugin/helpers.py
index b5ab1c18b..456038c2f 100644
--- a/src/lib/Bcfg2/Server/Plugin/helpers.py
+++ b/src/lib/Bcfg2/Server/Plugin/helpers.py
@@ -647,7 +647,13 @@ class XMLFileBacked(FileBacked):
if el.findall('./%sfallback' % Bcfg2.Server.XI_NAMESPACE):
self.logger.debug(msg)
else:
- self.logger.warning(msg)
+ self.logger.error(msg)
+ # add a FAM monitor for this path. this isn't perfect
+ # -- if there's an xinclude of "*.xml", we'll watch
+ # the literal filename "*.xml". but for non-globbing
+ # filenames, it works fine.
+ if fpath not in self.extra_monitors:
+ self.add_monitor(fpath)
parent = el.getparent()
parent.remove(el)
diff --git a/src/lib/Bcfg2/Server/Plugins/Metadata.py b/src/lib/Bcfg2/Server/Plugins/Metadata.py
index 4c1c31307..1d15656af 100644
--- a/src/lib/Bcfg2/Server/Plugins/Metadata.py
+++ b/src/lib/Bcfg2/Server/Plugins/Metadata.py
@@ -805,6 +805,11 @@ class Metadata(Bcfg2.Server.Plugin.Metadata,
def _handle_clients_xml_event(self, _): # pylint: disable=R0912
""" handle all events for clients.xml and files xincluded from
clients.xml """
+ # disable metadata builds during parsing. this prevents
+ # clients from getting bogus metadata during the brief time it
+ # takes to rebuild the clients.xml data
+ self.states['clients.xml'] = False
+
xdata = self.clients_xml.xdata
self.clients = []
self.clientgroups = {}
@@ -866,8 +871,9 @@ class Metadata(Bcfg2.Server.Plugin.Metadata,
self.clientgroups[clname].append(profile)
except KeyError:
self.clientgroups[clname] = [profile]
- self.states['clients.xml'] = True
self.update_client_list()
+ self.cache.expire()
+ self.states['clients.xml'] = True
def _get_condition(self, element):
""" Return a predicate that returns True if a client meets
@@ -895,7 +901,15 @@ class Metadata(Bcfg2.Server.Plugin.Metadata,
def _handle_groups_xml_event(self, _): # pylint: disable=R0912
""" re-read groups.xml on any event on it """
+ # disable metadata builds during parsing. this prevents
+ # clients from getting bogus metadata during the brief time it
+ # takes to rebuild the groups.xml data
+ self.states['groups.xml'] = False
+
self.groups = {}
+ self.group_membership = dict()
+ self.negated_groups = dict()
+ self.ordered_groups = []
# first, we get a list of all of the groups declared in the
# file. we do this in two stages because the old way of
@@ -920,10 +934,6 @@ class Metadata(Bcfg2.Server.Plugin.Metadata,
if grp.get('default', 'false') == 'true':
self.default = grp.get('name')
- self.group_membership = dict()
- self.negated_groups = dict()
- self.ordered_groups = []
-
# confusing loop condition; the XPath query asks for all
# elements under a Group tag under a Groups tag; that is
# infinitely recursive, so "all" elements really means _all_
@@ -956,6 +966,7 @@ class Metadata(Bcfg2.Server.Plugin.Metadata,
self.group_membership.setdefault(gname, [])
self.group_membership[gname].append(
self._aggregate_conditions(conditions))
+ self.cache.expire()
self.states['groups.xml'] = True
def HandleEvent(self, event):
@@ -1466,6 +1477,10 @@ class Metadata(Bcfg2.Server.Plugin.Metadata,
self.logger.debug("Metadata: Re-reading client list from database")
old = set(self.clients)
self.clients = self.list_clients()
+
+ # we could do this with set.symmetric_difference(), but we
+ # want detailed numbers of added/removed clients for
+ # logging
new = set(self.clients)
added = new - old
removed = old - new
@@ -1473,9 +1488,7 @@ class Metadata(Bcfg2.Server.Plugin.Metadata,
(len(added), added))
self.logger.debug("Metadata: Removed %s clients: %s" %
(len(removed), removed))
- # we could do this with set.symmetric_difference(), but we
- # want detailed numbers of added/removed clients for
- # logging
+
for client in added.union(removed):
self.cache.expire(client)
diff --git a/src/lib/Bcfg2/Server/Plugins/Reporting.py b/src/lib/Bcfg2/Server/Plugins/Reporting.py
index 8b8ada852..282de8247 100644
--- a/src/lib/Bcfg2/Server/Plugins/Reporting.py
+++ b/src/lib/Bcfg2/Server/Plugins/Reporting.py
@@ -54,7 +54,7 @@ class Reporting(Statistics, Threaded, PullSource):
self.logger.error(msg)
raise PluginInitError(msg)
- def start_threads(self):
+ # This must be loaded here for bcfg2-admin
try:
self.transport = Bcfg2.Options.setup.reporting_transport()
except TransportError:
@@ -63,6 +63,10 @@ class Reporting(Statistics, Threaded, PullSource):
if self.debug_flag:
self.transport.set_debug(self.debug_flag)
+ def start_threads(self):
+ """Nothing to do here"""
+ pass
+
def set_debug(self, debug):
rv = Statistics.set_debug(self, debug)
if self.transport is not None:
diff --git a/src/lib/Bcfg2/version.py b/src/lib/Bcfg2/version.py
index ae82724f3..196d77273 100644
--- a/src/lib/Bcfg2/version.py
+++ b/src/lib/Bcfg2/version.py
@@ -2,7 +2,7 @@
import re
-__version__ = "1.3.4"
+__version__ = "1.4.0pre1"
class Bcfg2VersionInfo(tuple): # pylint: disable=E0012,R0924
diff --git a/tools/export.py b/tools/export.py
index 6b0238bbb..df3c810d5 100755
--- a/tools/export.py
+++ b/tools/export.py
@@ -257,13 +257,11 @@ E.G. 1.2.0pre1 is a valid version.
startswith=True,
dryrun=options.dryrun)
find_and_replace('misc/bcfg2.spec', 'BuildRoot',
- 'BuildRoot: %%{_tmppath}/%%{name}-%%{version}%s-%%{release}-root-%%(%%{__id_u} -n)\n' %
- version_info['build'],
+ 'BuildRoot: %{_tmppath}/%{name}-%{version}%{?_pre_rc}-%{release}-root-%(%{__id_u} -n)\n',
startswith=True,
dryrun=options.dryrun)
find_and_replace('misc/bcfg2-selinux.spec', 'BuildRoot',
- 'BuildRoot: %%{_tmppath}/%%{name}-%%{version}%s-%%{release}-root-%%(%%{__id_u} -n)\n' %
- version_info['build'],
+ 'BuildRoot: %{_tmppath}/%{name}-%{version}%{?_pre_rc}-%{release}-root-%(%{__id_u} -n)\n',
startswith=True,
dryrun=options.dryrun)
# fix pre problem noted in