Showing with 1,893 additions and 732 deletions.
  1. +1 −0 .fixtures.yml
  2. +34 −1 CHANGELOG.md
  3. +11 −3 CONTRIBUTING.md
  4. +1 −1 Gemfile
  5. +51 −13 README.markdown
  6. +62 −15 files/RPM-GPG-KEY-puppetlabs
  7. +14 −0 files/solaris_start_puppet.sh
  8. +6 −0 lib/facter/settings.rb
  9. +74 −26 manifests/init.pp
  10. +60 −10 manifests/install.pp
  11. +110 −33 manifests/install/remove_packages.pp
  12. +46 −44 manifests/install/remove_packages_osx.pp
  13. +7 −7 manifests/osfamily/debian.pp
  14. +7 −5 manifests/osfamily/redhat.pp
  15. +77 −1 manifests/osfamily/solaris.pp
  16. +2 −2 manifests/osfamily/suse.pp
  17. +22 −7 manifests/params.pp
  18. +49 −18 manifests/prepare.pp
  19. +9 −8 manifests/prepare/package.pp
  20. +43 −19 manifests/prepare/puppet_config.pp
  21. +18 −10 manifests/service.pp
  22. +13 −0 manifests/service/solaris.pp
  23. +7 −0 manifests/windows/install.pp
  24. +55 −19 metadata.json
  25. +1 −0 spec/acceptance/nodesets/centos-5-x64.yml
  26. +1 −0 spec/acceptance/nodesets/centos-6-x64.yml
  27. +1 −0 spec/acceptance/nodesets/debian-6-x64.yml
  28. +1 −0 spec/acceptance/nodesets/debian-7-x64.yml
  29. +1 −0 spec/acceptance/nodesets/default.yml
  30. +1 −0 spec/acceptance/nodesets/ubuntu-1204-x64.yml
  31. +1 −0 spec/acceptance/nodesets/ubuntu-1404-x64.yml
  32. +54 −31 spec/classes/puppet_agent_osfamily_aix_spec.rb
  33. +69 −37 spec/classes/puppet_agent_osfamily_darwin_spec.rb
  34. +18 −6 spec/classes/puppet_agent_osfamily_debian_spec.rb
  35. +55 −38 spec/classes/puppet_agent_osfamily_redhat_spec.rb
  36. +326 −81 spec/classes/puppet_agent_osfamily_solaris_spec.rb
  37. +70 −33 spec/classes/puppet_agent_osfamily_suse_spec.rb
  38. +47 −0 spec/classes/puppet_agent_osfamily_windows_spec.rb
  39. +110 −64 spec/classes/puppet_agent_prepare_spec.rb
  40. +128 −39 spec/classes/puppet_agent_spec.rb
  41. +222 −154 spec/classes/puppet_agent_windows_install_spec.rb
  42. +8 −7 spec/spec_helper_acceptance.rb
1 change: 1 addition & 0 deletions .fixtures.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
fixtures:
repositories:
stdlib: "https://github.com/puppetlabs/puppetlabs-stdlib.git"
transition: "https://github.com/puppetlabs/puppetlabs-transition.git"
inifile: "https://github.com/puppetlabs/puppetlabs-inifile.git"
apt: "https://github.com/puppetlabs/puppetlabs-apt.git"
symlinks:
Expand Down
35 changes: 34 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,47 @@
All notable changes to this project will be documented in this file.
This project adheres to [Semantic Versioning](http://semver.org/).

## [1.2.0]

### Summary
Supports upgrades from puppet-agent packages! Applies to both PE and FOSS, for example upgrades from
PE 2015.3.2 to 2015.3.3 and puppet-agent 1.3.0 to 1.4.0 are supported. Upgrading from older Puppet 3
versions is also no longer explicitly prevented. Adds support for Solaris 11.

### Known issues
Carried-over from prior releases:
- For Windows, trigger an agent run after upgrade to get Puppet to create the necessary directory structures.
- Upgrades on EL4-based systems are not supported.
- Upgrades on Fedora systems are not supported.

Newly identified issues:
- Mac OS X Open Source package upgrades are not yet implemented.
- AIX package names are based on PowerPC architecture version. PowerPC 8 is not yet supported.

### Features
- Upgrades between puppet-agent packages, such as 2015.2.x to 2015.3.x.
- Adds support for Solaris 11.
- The `pluginsync` setting was deprecated in `puppet-agent 1.4.0`. This module removes it when upgrading to
that version or later unless otherwise managed.
- Remove the lower-version requirement. All Puppet 3 versions potentially can be upgraded, although
testing is only performed starting with Puppet/PE 3.8. Earlier versions likely work back to 3.5, as long as
the manifest is compiled using 3.7+ with future parser enabled.

### Bugfixes
- Fixes the release identification for Amazon Linux distributions to use EL 6 packages.
- Fix Debian upgrades for PE.
- Support upgrades of 32-bit Windows packages for PE (via pe_repo).
- Fixed an issue that would cause compilation to fail with `Unknown function: 'pe_compiling_server_aio_build'`
in some environments.

## [1.1.0]

### Summary
The addition of several OS support features and a considerable amount of compatibility and bug fixes.

### Known issues
While this release adds considerable features and bug fixes the following areas are known issues and require more work:
- For Windows, trigger an agent run after upgrade to get Puppet to create the nessesary directory structures.
- For Windows, trigger an agent run after upgrade to get Puppet to create the necessary directory structures.
- There is currently ongoing work to allow for upgrading from 2015.2.x to 2015.3.x.
- Solaris 11 support work is in progess, but currently still buggy.

Expand Down
14 changes: 11 additions & 3 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -80,12 +80,20 @@ Beaker tests with:
bundle exec rake acceptance

This will use the host described in `spec/acceptance/nodeset/default.yml`
by default. To run against another host, set the `BEAKER_set` environment
variable to the name of a host described by a `.yml` file in the
`nodeset` directory. For example, to run against CentOS 6.4:
and start from Puppet 3.8.6 by default.

To run against another host, set the `BEAKER_set` environment variable to
the name of a host described by a `.yml` file in the `nodeset` directory.
For example, to run against CentOS 6.4:

BEAKER_set=centos-64-x64 bundle exec rake acceptance

To run starting from a different Puppet version, set the
`PUPPET_CLIENT_VERSION` environment variable to a full version string. For
example, to start with Puppet 3.7.1:

PUPPET_CLIENT_VERSION=3.7.1 bundle exec rake acceptance

If you don't want to have to recreate the virtual machine every time you
can use `BEAKER_destroy=no` and `BEAKER_provision=no`. On the first run you will
at least need `BEAKER_provision` set to yes (the default). The Vagrantfile
Expand Down
2 changes: 1 addition & 1 deletion Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ group :test do
gem 'rspec-puppet', '~> 2.2'
gem 'puppetlabs_spec_helper', '~> 0.10'
gem 'metadata-json-lint', '~> 0.0'
gem 'rspec-puppet-facts', '~> 0.10'
gem 'rspec-puppet-facts', '~> 1.3'
end

group :system_tests do
Expand Down
64 changes: 51 additions & 13 deletions README.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,15 @@

## Overview

A module for upgrading Puppet 3.8 agents to puppet-agent in Puppet Collection 1 (i.e., Puppet 4).
A module for upgrading Puppet agents. Supports upgrading from Puppet 3 packages and puppet-agent packages, to puppet-agent packages (i.e. Puppet 4).

## Module Description

The puppet_agent module installs the Puppet Collection 1 repo (on systems that support repositories); migrates configuration required by Puppet to new locations used by puppet-agent; and installs the puppet-agent package, removing the previous Puppet installation. This module expects Puppet to be installed from packages.
The puppet_agent module installs the Puppet Collection 1 repo (as a default, and on systems that support repositories); migrates configuration required by Puppet to new locations used by puppet-agent; and installs the puppet-agent package, removing the previous Puppet installation. When starting from Puppet 3, it will upgrade to the latest Puppet open-source release, or to the latest puppet-agent package supported by your PE installation.

If a package_version parameter is provided, it will ensure that puppet-agent version is installed. The package_version parameter is required to perform upgrades starting from a puppet-agent (Puppet 4) package.

This module expects Puppet to be installed from packages.

## Setup

Expand All @@ -37,14 +41,18 @@ The puppet_agent module installs the Puppet Collection 1 repo (on systems that s

### Setup Requirements

Your agents must be running Puppet 3.8 with `stringify_facts` set to 'false'. Agents should already be pointed at a master running Puppet Server 2.1 or greater, and thus successfully applying catalogs compiled with the Puppet 4 language.
Your agents must be running Puppet 3 with `stringify_facts` set to 'false', or Puppet 4+. Agents should already be pointed at a master running Puppet Server 2.1 or greater, and thus successfully applying catalogs compiled with the Puppet 4 language.

Puppet 3.7 with future parser is required to compile this module, meaning it may be applied to masterless Puppet 3.7+, or earlier Puppet 3 agents connecting to a Puppet 3.7+ master.

### Beginning with puppet_agent

Install the puppet_agent module with `puppet module install puppetlabs-puppet_agent`.

## Usage

### Puppet 3 Upgrades

Add the class to agents you want to upgrade:

~~~puppet
Expand All @@ -61,15 +69,33 @@ As part of preparing the agent for Puppet 4, the module performs several signifi
* Resets logfile in MCollective's server.cfg and client.cfg.
* Adds new libdir and plugin.yaml locations to MCollective's server.cfg and client.cfg.

### Puppet 4 Upgrades

Add the class to agents you want to upgrade, specifying the desired puppet-agent version:

~~~puppet
class {'::puppet_agent':
package_version => '1.4.0',
}
~~~

This will ensure the version `1.4.0` of the puppet-agent package is installed. For version `1.4.0` and later, it will also remove the deprecated `pluginsync` setting from `puppet.conf`, unless explicitly managed elsewhere.

##Reference

###Public classes
* [`puppet_agent`](#class-puppetagent)

###Private classes
* `puppet_agent::install`: Installs packages.
* `puppet_agent::install::remove_packages`: For platforms that can't perform in-place upgrades, removes the old packages.
* `puppet_agent::install::remove_packages_osx`: Removes the old packages on Mac OS X.
* `puppet_agent::osfamily::*`: Platform-specific preparation performed before upgrades.
* `puppet_agent::prepare`: Prepares the agent for upgrade.
* `puppet_agent::prepare::package`: Stages packages locally for install, on platforms that can't install from remote packages.
* `puppet_agent::prepare::*`: Prepare various file and ssl configuration.
* `puppet_agent::service`: Ensures the services are running.
* `puppet_agent::windows::install`: Handles Windows package installation.

###Parameters

Expand All @@ -79,10 +105,24 @@ As part of preparing the agent for Puppet 4, the module performs several signifi

The architecture version you wish to install. Defaults to `$::architecture`. This parameter is [ignored](#known-issues) in Windows Server 2003.

#####`collection`

The Puppet Collection to track. Defaults to `PC1`.

#####`is_pe`

Install from Puppet Enterprise rpos. Enabled if communicating with a PE master.

#####`package_name`

The package to upgrade to, i.e., `puppet-agent`. Currently, the default and only accepted value is `puppet-agent`.

#####`package_version`

The package version to upgrade to. When upgrading from Puppet < 4.0, defaults to the puppet master's latest supported version
if compiled with A PE master or undef otherwise (meaning get the latest Open Source release). Explicitly specify a version to
upgrade from puppet-agent packages (implying Puppet >= 4.0).

#####`service_names`

An array of services to start, normally `puppet` and `mcollective`. If the array is empty, no services are started.
Expand All @@ -93,13 +133,7 @@ Alternate source from which you wish to download the latest version of Puppet.

## Limitations

This module supports:

* RHEL 5, 6, 7
* Centos 5, 6, 7
* Debian 6, 7
* Ubuntu 12.04, 14.04
* Windows Server 2003 or later
Mac OS X Open Source packages are currently not supported.

###Known issues

Expand All @@ -112,10 +146,9 @@ In addition, there are several known issues with Windows:
* On Windows Server 2003, only x86 is supported, and the `arch` parameter is ignored. If you try to force an upgrade to x64, Puppet installs the x86 version with no error message.
* On Windows Server 2003 with Puppet Enterprise, the default download location is unreachable. You can work around this issue by specifying an alternate download URL in the `source` parameter.

Specifically in the 1.1.0 Release:
Specifically in the 1.2.0 Release:
* For Windows, you must trigger an agent run after upgrading so that Puppet can create the necessary directory structures.
* Upgrading from 2015.2.x to 2015.3.x is not yet supported.
* Solaris 11 is not yet supported.
* AIX package names are based on PowerPC architecture version. PowerPC 8 is not yet supported.

##Development

Expand All @@ -125,3 +158,8 @@ We want to keep it as easy as possible to contribute changes so that our modules

To contribute to the puppet_agent module, see [Contributing.md](https://github.com/puppetlabs/puppetlabs-puppet_agent/blob/master/CONTRIBUTING.md). You can also read the complete module contribution guide [on the Puppet Labs wiki.](http://projects.puppetlabs.com/projects/module-site/wiki/Module_contributing)

## Maintenance

Maintainers: Michael Smith <michael.smith@puppet.com>, Brandon High <brandon.high@puppet.com>

Tickets: https://tickets.puppetlabs.com/browse/MODULES.
77 changes: 62 additions & 15 deletions files/RPM-GPG-KEY-puppetlabs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
-----BEGIN PGP PUBLIC KEY BLOCK-----
Version: GnuPG/MacGPG2 v2.0.17 (Darwin)
Version: GnuPG v1

mQINBEw3u0ABEAC1+aJQpU59fwZ4mxFjqNCgfZgDhONDSYQFMRnYC1dzBpJHzI6b
fUBQeaZ8rh6N4kZ+wq1eL86YDXkCt4sCvNTP0eF2XaOLbmxtV9bdpTIBep9bQiKg
Expand All @@ -13,18 +13,65 @@ wrjhMQQOOSZOb3vBRvBZNnnxPrcdjUUm/9cVB8VcgI5KFhG7hmMCwH70tpUWcZCN
NlI1wj/PJ7Tlxjy44f1o4CQ5FxuozkiITJvh9CTg+k3wEmiaGz65w9jRl9ny2gEl
f4CR5+ba+w2dpuDeMwiHJIs5JsGyJjmA5/0xytB7QvgMs2q25vWhygsmUQARAQAB
tEdQdXBwZXQgTGFicyBSZWxlYXNlIEtleSAoUHVwcGV0IExhYnMgUmVsZWFzZSBL
ZX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9ix/V0NtoMFfyY9/Eo7q6xlmZf18i6pDBAMgSSwat1xvqesZ5we
58kNsuYVmITvsuOOhEQWUb20TJogBVILD+/KeD3BWjwicMXuPVUe5S56Hp677K8u
NSsW6HcJU0dzHasQgXPH5fnrrRNttF8yDEulMySRvjDsNCMJSYVAPjIvNnNcDOMQ
tz9OCwUZlzeXGjtS7PBfRkSbXlaOt1jC+0xTVMaOMjbp2CTbgrcpvY55ScLJtDWY
vHqpXHRoV3bVt4pEb27dK2nwcdel8uH9rOdsJjklq85KE5eA2Crd/T9QiYuPK4W/
bvHQdAXF9w==
=t3lA
-----END PGP PUBLIC KEY BLOCK-----
14 changes: 14 additions & 0 deletions files/solaris_start_puppet.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
#!/bin/bash

puppet_pid=$1
while $(kill -0 ${puppet_pid:?}); do
sleep 5
done

function start_service() {
service="${1:?}"
/opt/puppetlabs/bin/puppet resource service "${service:?}" ensure=running enable=true
}

start_service puppet
start_service mcollective
6 changes: 6 additions & 0 deletions lib/facter/settings.rb
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,12 @@
end
end

Facter.add('puppet_client_datadir') do
setcode do
Puppet.settings['client_datadir']
end
end

Facter.add('mco_confdir') do
setcode do
File.expand_path(File.join(Puppet.settings['confdir'],'../../mcollective/etc'))
Expand Down
Loading