diff options
author | Dan Prince <dprince@redhat.com> | 2015-02-04 21:45:44 -0500 |
---|---|---|
committer | Dan Prince <dprince@redhat.com> | 2015-02-05 10:12:48 -0500 |
commit | f8a9c530e0694b956fb5819dd46e38380ecc58e2 (patch) | |
tree | 70873d123e0a4e579401da915fe4df41533684a9 /puppet/overcloud_controller.pp | |
parent | 6ba5a410628bcc611923f798baa807ef799178d5 (diff) |
puppet: Add EnablePackageInstall option
This adds an option which enables package installation via
Yum when Puppet executes. Users might want to disable Yum
installation of packages via puppet when using pre-installed
images.
The option is off by default: meaning that Puppet will no
longer install packages by default. Users will need to
enable the EnablePackageInstall in order to get
the previous behavior.
The intent is to use the default_parameters section
of the Heat environment to allow users to cleanly enable this
features without wiring it into the top level. This is because
the new parameter is Puppet specific and doesn't really apply to
other implementations. Kilo Heat already has support for
default_parameters and so does python-heatclient.
NOTE: most TripleO users do not yet have the heatclient
features because setup-clienttools in tripleo-incubator only installs
releases via pip. It is for these reasons the default_parameters
section in overcloud-resource-registry-puppet.yaml is commented out
for now.
Change-Id: I3af71b801b87d080b367d9e4a1fb44c1bfea6e87
Diffstat (limited to 'puppet/overcloud_controller.pp')
-rw-r--r-- | puppet/overcloud_controller.pp | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/puppet/overcloud_controller.pp b/puppet/overcloud_controller.pp index 6af54a5e..acfea686 100644 --- a/puppet/overcloud_controller.pp +++ b/puppet/overcloud_controller.pp @@ -13,6 +13,17 @@ # License for the specific language governing permissions and limitations # under the License. +if !str2bool(hiera('enable_package_install', 'false')) { + case $::osfamily { + 'RedHat': { + Package { provider => 'norpm' } # provided by tripleo-puppet + } + default: { + warning('enable_package_install option not supported.') + } + } +} + if hiera('step') >= 1 { include ::ntp |