You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+23-68Lines changed: 23 additions & 68 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -9,9 +9,9 @@
9
9
*[Beginning with concat](#beginning-with-concat)
10
10
4.[Usage - Configuration options and additional functionality](#usage)
11
11
5.[Reference - An under-the-hood peek at what the module is doing and how](#reference)
12
-
*[Public Defines](#public-defines)
12
+
*[Defines](#defines)
13
13
*[Parameters](#parameters)
14
-
*[Deprecations](#deprecations)
14
+
*[Removed functionality](#removed-functionality)
15
15
6.[Limitations - OS compatibility, etc.](#limitations)
16
16
7.[Development - Guide for contributing to the module](#development)
17
17
@@ -21,14 +21,13 @@ The concat module lets you construct files from multiple ordered fragments of te
21
21
22
22
##Module Description
23
23
24
-
The concat module lets you gather `concat::fragment` resources from your other modules and order them through a single `concat` resource into a coherent file. It does this through a Ruby script and a temporary holding space for the fragments.
24
+
The concat module lets you gather `concat::fragment` resources from your other modules and order them into a coherent filethrough a single `concat` resource.
25
25
26
26
##Setup
27
27
28
28
###What concat affects
29
29
30
-
* Installs `concatfragments.rb`.
31
-
* Adds a `concat/` directory into Puppet's `vardir`.
30
+
The concat module requires the [file_concat module](https://forge.puppetlabs.com/ispavailability/file_concat). If you don't have file_concat installed, concat installs it for you.
32
31
33
32
###Beginning with concat
34
33
@@ -123,9 +122,7 @@ When you're finished, the motd file will look something like this:
123
122
124
123
##Reference
125
124
126
-
**Note**: Several of this module's parameters and features have been deprecated. See the [Deprecations](#deprecations) section below.
127
-
128
-
###Public defines
125
+
###Defines
129
126
*`concat`: Manages a file, compiled from one or more text fragments.
130
127
*`concat::fragment`: Manages a fragment of text to be compiled into a file.
131
128
@@ -143,15 +140,6 @@ Specifies whether (and how) to back up the destination file before overwriting i
143
140
144
141
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'.
145
142
146
-
147
-
#####`ensure_newline`
148
-
149
-
Specifies whether to ensure there's a new line at the end of each fragment. Valid options: 'true' and 'false'. Default value: 'false'.
150
-
151
-
#####`force`
152
-
153
-
In case no fragments have been added, this parameter specifies whether to go ahead and create a potentially empty file. Valid options: 'true' and 'false'. Default value: 'false'.
154
-
155
143
#####`group`
156
144
157
145
Specifies a permissions group for the destination file. Valid options: a string containing a group name. Default value: undefined.
@@ -168,12 +156,10 @@ You can override this setting for individual fragments by adjusting the `order`
168
156
169
157
#####`owner`
170
158
171
-
172
159
Specifies the owner of the destination file. Valid options: a string containing a username. Default value: undefined.
173
160
174
161
#####`path`
175
162
176
-
177
163
Specifies a destination file for the combined fragments. Valid options: a string containing an absolute path. Default value: the title of your declared resource.
178
164
179
165
#####`replace`
@@ -184,30 +170,24 @@ Specifies whether to overwrite the destination file if it already exists. Valid
184
170
185
171
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.
186
172
187
-
#####`warn`
188
-
189
-
Specifies whether to add a warning message at the top of the destination file so users know it was autogenerated by Puppet. Valid options: 'true', 'false', or a string to be delivered as a warning message. Default value: 'false'.
173
+
#####`warn_header`
190
174
175
+
Specifies whether to add a header message at the top of the destination file so users know it was autogenerated by Puppet. In earlier versions of the concat module, this parameter was called `warn`. Valid options: the booleans 'true' and 'false', or a string to serve as the header. Default value: 'false'.
191
176
192
-
If you set this parameter to 'true', Puppet adds the following message:
177
+
If you set 'warn_header' to 'true', `concat` adds the following message:
193
178
194
179
~~~
195
180
# This file is managed by Puppet. DO NOT EDIT.
196
181
~~~
197
182
198
183
####`concat::fragment`
199
184
200
-
201
185
Except where noted, all the below parameters are optional.
202
186
203
187
#####`content`
204
188
205
189
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.
206
190
207
-
#####`ensure`
208
-
209
-
Specifies whether the fragment should be included in the destination file or discarded. Valid options: 'present' and 'absent'. Default value: 'present'.
210
-
211
191
#####`order`
212
192
213
193
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'.
@@ -220,51 +200,26 @@ Specifies a file to read into the content of the fragment. **Note**: You must su
220
200
221
201
*Required.* Specifies the destination file of the fragment. Valid options: a string containing an absolute path.
222
202
223
-
###Deprecations
224
-
225
-
**`concat` has the following deprecations**
226
-
227
-
#####`gnu`
228
-
229
-
Generates a catalog compile time warning and has no effect. This parameter was silently ignored in version `1.0.0` and will be removed in a future release.
230
-
231
-
#####stringified 'true'/'false' values deprecated in `warn`
232
-
233
-
Passing stringified boolean values (strings of 'true' and 'false') to the `warn` parameter of `concat` is deprecated. Generates a catalog compile time warning, and will be silently treated as the concatenated file header/warning message in a future release.
234
-
235
-
Please migrate to using the Puppet DSL's native [Boolean data
**`concat::fragment` has the following deprecations**
240
-
241
-
#####`backup`
242
-
243
-
Generates a catalog compile time warning and has no effect. In the `1.0.0` release this parameter controlled file bucketing of the file fragment. Bucketing the fragment(s) is redundant with bucketing the final concatenated file and this feature has been removed.
244
-
245
-
246
-
#####`group`
247
-
248
-
Generates a catalog compile time warning and has no effect. Had no user-visible effect in version `1.0.0` and will be removed in a future release.
249
-
250
-
#####`mode`
251
-
252
-
Generates a catalog compile time warning and has no effect. Had no user-visible effect in version `1.0.0` and will be removed in a future release.
253
-
254
-
255
-
#####`owner`
256
-
257
-
Generates a catalog compile time warning and has no effect. Had no user-visible effect in version `1.0.0` and will be removed in a future release.
203
+
###Removed functionality
258
204
259
-
#####file paths are deprecated in `ensure`
205
+
The following functionality existed in previous versions of the concat module, but were removed in version 2.0.0:
260
206
261
-
Passing a value other than 'present' or 'absent' in the `ensure` parameter of `concat::fragment` is **deprecated**, and generates a catalog compile time warning. The warning will become a catalog compilation failure in a future release.
207
+
Parameters removed from `concat`:
208
+
*`ensure_newline`
209
+
*`force`
210
+
*`warn` (replaced by `warn_header`)
262
211
263
-
If you want to use the content of a file as a fragment please use the [`source`](#source) parameter.
212
+
Parameters removed from `concat::fragment`:
213
+
*`ensure`
214
+
*`gnu`
215
+
*`backup`
216
+
*`group`
217
+
*`mode`
218
+
*`owner`
264
219
265
-
####`concat::setup`
220
+
The `concat::setup` class has also been removed.
266
221
267
-
The `concat::setup` class should no longer be directly included in the manifest. It will be removed in a future release.
222
+
Prior to concat version 2.0.0, if you set the `warn` parameter to a string value of 'true', 'false', 'yes', 'no', 'on', or 'off', the module translated the string to the corresponding boolean value. In concat version 2.0.0 and newer, the `warn_header` parameter treats those values the same as other strings and uses them as the content of your header message. To avoid that, pass the 'true' and 'false' values as booleans instead of strings.
0 commit comments