Skip to content

Commit

Permalink
Merge pull request #313 from bmjen/2.0.0-prep
Browse files Browse the repository at this point in the history
Release 2.0.0 prep
  • Loading branch information
Morgan Haskel committed May 12, 2015
2 parents d654dea + 26033e6 commit 5ab5672
Show file tree
Hide file tree
Showing 3 changed files with 120 additions and 9 deletions.
35 changes: 35 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,38 @@
=======
##2015-05-12 - Supported Release 2.0.0
###Summary

This is a major release. Includes re-implementation of concat to use native Type and Providers, resulting in significantly improved performance and testability. Also includes a bugfix to alpha ordering of fragments.

####Features
- Re-implementation of concat to use native Type and Providers.

####Bugfixes
- Fixes a bug in alpha ordering of fragments.


##2015-05-12 - Supported Release 1.2.2
###Summary

This release includes a bugfix.

####Bugfixes
- Fixes a bug introduced by MODULES-1700, in handling default retrieval of fragment backup parameter.

##2015-04-14 - Supported Release 1.2.1
###Summary

This release includes bugfixes, test improvements, and a rewritten README.

####Bugfixes

- Verifies existence of $is_pe before using it.
- Adds validation for $order param to not allow restricted characters.
- Sets the group id on Fragments for versions of Facter that contain the $gid fact.
- Sets the script group to 0 if the script is owned by root.
- Explicitly sets script and concat directories to the same owner and group.
- Re-adds support for fragment backup, so that static compiler can work with filebucket (MODULES-1700).

##2015-02-17 - Supported Release 1.2.0
###Summary

Expand Down
88 changes: 82 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -120,9 +120,13 @@ When you're finished, the motd file will look something like this:
* `concat`: Manages a file, compiled from one or more text fragments.
* `concat::fragment`: Manages a fragment of text to be compiled into a file.

###Types
* `concat_file`: Generates a file with content from fragments sharing a common unique tag.
* `concat_fragment`: Manages the fragment.

###Parameters

####`concat`
####Define: `concat`

All the parameters listed below are optional.

Expand All @@ -134,6 +138,10 @@ Specifies whether (and how) to back up the destination file before overwriting i

Specifies whether the destination file should exist. Setting to 'absent' tells Puppet to delete the destination file if it exists, and negates the effect of any other parameters. Valid options: 'present' and 'absent'. Default value: 'present'.

#####`ensure_newline`

Specifies whether to add a line break at the end of each fragment that doesn't already end in one. Valid options: 'true' and 'false'. Default value: 'false'.

#####`force`

Deprecated as of concat v2.0.0. Has no effect.
Expand Down Expand Up @@ -178,7 +186,7 @@ If you set 'warn' to 'true', `concat` adds the following message:
# This file is managed by Puppet. DO NOT EDIT.
~~~

####`concat::fragment`
####Define: `concat::fragment`

Except where noted, all the below parameters are optional.

Expand All @@ -202,12 +210,80 @@ Specifies a file to read into the content of the fragment. **Note**: You must su

*Required.* Specifies the destination file of the fragment. Valid options: a string containing an absolute path.

###Removed functionality

The following functionality existed in previous versions of the concat module, but were removed in version 2.0.0:
####Type: `concat_file`

#####`backup`

Specifies whether (and how) to back up the destination file before overwriting it. Your value gets passed on to Puppet's [native `file` resource](https://docs.puppetlabs.com/references/latest/type.html#file-attribute-backup) for execution. Valid options: 'true', 'false', or a string representing either a target filebucket or a filename extension beginning with ".". Default value: 'puppet'.

#####`ensure`

Specifies whether the destination file should exist. Setting to 'absent' tells Puppet to delete the destination file if it exists, and negates the effect of any other parameters. Valid options: 'present' and 'absent'. Default value: 'present'.

#####`ensure_newline`

Specifies whether to add a line break at the end of each fragment that doesn't already end in one. Valid options: 'true' and 'false'. Default value: 'false'.

#####`group`

Specifies a permissions group for the destination file. Valid options: a string containing a group name. Default value: undefined.

#####`mode`

Specifies the permissions mode of the destination file. Valid options: a string containing a permission mode value in octal notation. Default value: '0644'.

#####`order`

Specifies a method for sorting your fragments by name within the destination file. Valid options: 'alpha' (e.g., '1, 10, 2') or 'numeric' (e.g., '1, 2, 10'). Default value: 'numeric'.

You can override this setting for individual fragments by adjusting the `order` parameter in their `concat::fragment` declarations.

#####`owner`

Specifies the owner of the destination file. Valid options: a string containing a username. Default value: undefined.

#####`path`

Specifies a destination file for the combined fragments. Valid options: a string containing an absolute path. Default value: the title of your declared resource.

#####`replace`

Specifies whether to overwrite the destination file if it already exists. Valid options: 'true' and 'false'. Default value: 'true'.

####`tag`

*Required.* Specifies a unique tag reference to collect all concat_fragments with the same tag.

#####`validate_cmd`

Specifies a validation command to apply to the destination file. Requires Puppet version 3.5 or newer. Valid options: a string to be passed to a file resource. Default value: undefined.

####Type: `concat_fragment`

#####`content`

Supplies the content of the fragment. **Note**: You must supply either a `content` parameter or a `source` parameter. Valid options: a string. Default value: undef.

#####`order`

Reorders your fragments within the destination file. Fragments that share the same order number are ordered by name. Valid options: a string (recommended) or an integer. Default value: '10'.

#####`source`

Specifies a file to read into the content of the fragment. **Note**: You must supply either a `content` parameter or a `source` parameter. Valid options: a string or an array, containing one or more Puppet URLs. Default value: undefined.

#####`tag`

*Required.* Specifies a unique tag to be used by concat_file to reference and collect content.

#####`target`

*Required.* Specifies the destination file of the fragment. Valid options: a string containing an absolute path.

###Removed functionality

Parameters removed from `concat`:
* `ensure_newline`
The following functionality existed in previous versions of the concat module, but was removed in version 2.0.0:

Parameters removed from `concat::fragment`:
* `gnu`
Expand Down
6 changes: 3 additions & 3 deletions metadata.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,9 @@
"source": "https://github.com/puppetlabs/puppetlabs-concat",
"project_page": "https://github.com/puppetlabs/puppetlabs-concat",
"issues_url": "https://tickets.puppetlabs.com/browse/MODULES",
"dependencies": [
{"name":"puppetlabs/stdlib","version_requirement":">= 4.5.0 < 5.0.0"}
],
"operatingsystem_support": [
{
"operatingsystem": "RedHat",
Expand Down Expand Up @@ -104,7 +107,4 @@
"version_requirement": "3.x"
}
],
"dependencies": [
{"name":"puppetlabs/stdlib","version_requirement":">= 4.5.0 < 5.0.0"}
]
}

0 comments on commit 5ab5672

Please sign in to comment.