Skip to content

Commit

Permalink
Update concat to 30fbfe1
Browse files Browse the repository at this point in the history
30fbfe1 Merge pull request redhat-openstack#277 from buzzdeee/concat_order_verification_fix
a3d8632 Merge pull request redhat-openstack#230 from duritong/set_group_for_fragments
b897904 When testing the order parameter on sanity, make sure that pattern matching is only exercised on strings. Integers don't like that.
0aa6c63 set group of fragments to gid
eb04c55 Merge pull request redhat-openstack#275 from mhaskel/validate_order
2ca56da Add validation for order parameter
2d60bcb Merge pull request redhat-openstack#270 from raphink/dev/is_pe
9e1a8f8 Merge pull request redhat-openstack#274 from puppetlabs/revert-273-fix_strict_vars
410e180 Revert "Lookup is_pe fact with getvar"
a4133c4 Merge pull request redhat-openstack#273 from cmurphy/fix_strict_vars
59d7a3a Lookup is_pe fact with getvar
9b3f4b3 Merge pull request redhat-openstack#271 from nibalizer/master
0e0dc74 Removing travis badge
6a0e9cc Check if $is_pe exists before using it
f6e9f0a Merge pull request redhat-openstack#269 from mhaskel/merge_1.2.x_into_master
3173e96 1.2.0 prep
c7c0e4a Merge pull request redhat-openstack#266 from mhaskel/remove_shell
7eb14b7 Remove shell script
20d0a5f Merge pull request redhat-openstack#265 from mhaskel/validation_test_fix
36ff0ea The validation acceptance test is very Linux specific
164a9a0 Merge pull request redhat-openstack#263 from cmurphy/fix_validate_cmd
a198e5d Fix validate_cmd file resource parameter
3a634af Merge pull request redhat-openstack#243 from jmkeyes/add-validation-command
bccd7ed Merge pull request redhat-openstack#262 from cyberious/master
520287f Fix Solaris 10 errors in tests and more issues with Windows checks of owner
88869c6 Merge pull request redhat-openstack#260 from cyberious/master
b9b13d2 Currently sorting by numeric and the ruby file is not supported, this fixes that
7bc211c MODULES-1764 Fix missing method for check_is_owned_by for windows
40200a6 Merge pull request redhat-openstack#261 from mhaskel/merge_1.1.x_to_master
3b2e37a MODULES-1456 - make sure ruby is in path on PE
fa5c1cf Merge pull request redhat-openstack#249 from nosolutions/master
9036086 Merge pull request redhat-openstack#258 from cmurphy/rspec
aacf1bd Pin rspec gems
2518958 Merge pull request redhat-openstack#256 from cyberious/BeakerRspecPin
7d49b5f Beaker-Rspec broken on Windows, enable ability to pin to older version until fixed
be93344 Merge pull request redhat-openstack#255 from hunner/fix_pending
cff25a8 Fix pending tests
7ed3f56 Merge pull request redhat-openstack#254 from cmurphy/master
ce90edc Add IntelliJ files to the ignore list
aab8e17 Merge pull request redhat-openstack#250 from laurenrother/summary
dbf3124 Merge pull request redhat-openstack#252 from cmurphy/master
ee87c65 Add json gem
440a6b7 Update .travis.yml, Gemfile, Rakefile, and CONTRIBUTING.md
8fb09fb Merge pull request redhat-openstack#251 from cmurphy/puppet_27
6f1e97a Define travis matrix in .sync.yml
027484d Add metadata summary per FM-1523
4fc1dfc use concatfragments.rb on AIX
708def1 Merge pull request redhat-openstack#248 from mhaskel/merge_1.1.x
d3446f6 Merge remote-tracking branch 'upstream/1.1.x' into merge_1.1.x
351d5f6 Merge pull request redhat-openstack#247 from mhaskel/work_around_cert_issues
dc9f4b3 Use a path that works on both 32 and 64-bit windows
0133d3a Add acceptance test for validate_cmd parameter.
79c5e45 Add unit tests for validate_cmd parameter.
09a01d8 Ensure validate_cmd is a string and fail explicitly otherwise.
5f5b892 Merge pull request redhat-openstack#245 from mhaskel/merge_1.1.x
0613485 Merge remote-tracking branch 'upstream/1.1.x' into merge_1.1.x
b69246a Merge pull request redhat-openstack#244 from mhaskel/work_around_cert_issues
c79d81a Work around cert issues on solaris and windows
5619355 Support running a validation command on the destination file.
d97a047 Merge pull request redhat-openstack#231 from GeoffWilliams/poison_exec_defaults_fix
520224f Merge pull request redhat-openstack#242 from mhaskel/test
ab06c2b Merge pull request redhat-openstack#241 from cyberious/InstallCert
8cb4c24 Use apply manifest instead of timeout transaction if it does hang
75dd725 Merge pull request redhat-openstack#240 from mhaskel/1.1.2-prep
ea3d6e3 1.1.2 prep
73c7896 Merge pull request redhat-openstack#239 from mhaskel/pull_master_to_1.1.x
fe9730a Merge pull request redhat-openstack#238 from mhaskel/windows_cert_fix
624ae75 Install certs on windows
ed6efe8 Reset poisoned defaults from Exec
  • Loading branch information
xbezdick committed Mar 3, 2015
1 parent 1f9aa29 commit a63e8a9
Show file tree
Hide file tree
Showing 35 changed files with 492 additions and 419 deletions.
2 changes: 1 addition & 1 deletion Puppetfile
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ mod 'common',
:git => 'https://github.com/purpleidea/puppet-common.git'

mod 'concat',
:commit => '644fb1b6dc8b64accc4d1208d6127b79a08a38b7',
:commit => '30fbfe11aaf6d9d90e2cbf8cb5e20f2bd7748123',
:git => 'https://github.com/puppetlabs/puppetlabs-concat.git'

mod 'firewall',
Expand Down
2 changes: 2 additions & 0 deletions concat/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,5 @@ spec/fixtures/
.vagrant/
.bundle/
coverage/
.idea/
*.iml
8 changes: 8 additions & 0 deletions concat/.sync.yml
Original file line number Diff line number Diff line change
@@ -1 +1,9 @@
---
.travis.yml:
includes:
- rvm: 1.8.7
env: PUPPET_GEM_VERSION="~> 3.0"
- rvm: 1.9.3
env: PUPPET_GEM_VERSION="~> 3.0"
- rvm: 2.0.0
env: PUPPET_GEM_VERSION="~> 3.0"
2 changes: 1 addition & 1 deletion concat/.travis.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
language: ruby
bundler_args: --without development
bundler_args: --without system_tests
script: "bundle exec rake validate && bundle exec rake lint && bundle exec rake spec SPEC_OPTS='--format documentation'"
matrix:
fast_finish: true
Expand Down
32 changes: 27 additions & 5 deletions concat/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,31 @@
##2014-09-10 - Supported Release 1.1.1
##2015-02-17 - Supported Release 1.2.0
###Summary

This release includes a number of bugfixes and adds support for running a validation command when using puppet >= 3.5.0.

####Features
- Support running a validation command for Puppet >= 3.5.0

####Bugfixes
- Reset poisoned defaults from Exec
- Use concatfragments.rb on AIX since it doesn't support print0
- Make sure ruby is in the path for PE (MODULES-1456)
- Fix missing method for check_is_owned_by for windows (MODULES-1764)
- Fix sort by numeric

##2014-10-28 - Supported Release 1.1.2
###Summary

This release includes bugfixes and test improvements. The module was tested against SLES10 and SLES12 and found to work against those platforms with no module improvements. Metadata was updated to include those as supported platforms.

####Bugfixes
- newline didn't work for Windows and Solaris. This has been fixed.
- Install certs on Windows for acceptance tests
- Update tests to work with strict variables (no module updates were required)
- Update tests to work on Windows
- Fix typo in CHANGELOG.md

##2014-09-10 - Supported Release 1.1.1
###Summary

This is a bugfix release, and the first supported release of the 1.1.x series.
Expand All @@ -19,7 +45,6 @@ This is a bugfix release, and the first supported release of the 1.1.x series.
- Synchronized files for more consistency across modules via modulesync

##2014-05-14 - Release 1.1.0

###Summary

This release is primarily a bugfix release since 1.1.0-rc1.
Expand All @@ -34,7 +59,6 @@ This release is primarily a bugfix release since 1.1.0-rc1.
- Fix newlines

##2014-01-03 - Release 1.1.0-rc1

###Summary

This release of concat was 90% written by Joshua Hoblitt, and the module team
Expand Down Expand Up @@ -124,7 +148,6 @@ This is a supported release. No functional changes were made from 1.0.1.


##2014-02-12 - 1.0.1

###Summary

Minor bugfixes for sorting of fragments and ordering of resources.
Expand All @@ -137,7 +160,6 @@ fragments.


##2013-08-09 - 1.0.0

###Summary

Many new features and bugfixes in this release, and if you're a heavy concat
Expand Down
22 changes: 4 additions & 18 deletions concat/CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,11 +41,9 @@ Checklist (and a short version for the impatient)

* Pre-requisites:

- Sign the [Contributor License Agreement](https://cla.puppetlabs.com/)

- Make sure you have a [GitHub account](https://github.com/join)

- [Create a ticket](http://projects.puppetlabs.com/projects/modules/issues/new), or [watch the ticket](http://projects.puppetlabs.com/projects/modules/issues) you are patching for.
- [Create a ticket](https://tickets.puppetlabs.com/secure/CreateIssue!default.jspa), or [watch the ticket](https://tickets.puppetlabs.com/browse/) you are patching for.

* Preferred method:

Expand Down Expand Up @@ -94,17 +92,7 @@ The long version
whitespace or other "whitespace errors". You can do this by
running "git diff --check" on your changes before you commit.

2. Sign the Contributor License Agreement

Before we can accept your changes, we do need a signed Puppet
Labs Contributor License Agreement (CLA).

You can access the CLA via the [Contributor License Agreement link](https://cla.puppetlabs.com/)

If you have any questions about the CLA, please feel free to
contact Puppet Labs via email at cla-submissions@puppetlabs.com.

3. Sending your patches
2. Sending your patches

To submit your changes via a GitHub pull request, we _highly_
recommend that you have them on a topic branch, instead of
Expand All @@ -124,7 +112,7 @@ The long version
in order to open a pull request.


4. Update the related GitHub issue.
3. Update the related GitHub issue.

If there is a GitHub issue associated with the change you
submitted, then you should update the ticket to include the
Expand Down Expand Up @@ -220,14 +208,12 @@ review.
Additional Resources
====================

* [Getting additional help](http://projects.puppetlabs.com/projects/puppet/wiki/Getting_Help)
* [Getting additional help](http://puppetlabs.com/community/get-help)

* [Writing tests](http://projects.puppetlabs.com/projects/puppet/wiki/Development_Writing_Tests)

* [Patchwork](https://patchwork.puppetlabs.com)

* [Contributor License Agreement](https://projects.puppetlabs.com/contributor_licenses/sign)

* [General GitHub documentation](http://help.github.com/)

* [GitHub pull request documentation](http://help.github.com/send-pull-requests/)
Expand Down
37 changes: 28 additions & 9 deletions concat/Gemfile
Original file line number Diff line number Diff line change
@@ -1,25 +1,44 @@
source ENV['GEM_SOURCE'] || "https://rubygems.org"

group :development, :test do
def location_for(place, fake_version = nil)
if place =~ /^(git:[^#]*)#(.*)/
[fake_version, { :git => $1, :branch => $2, :require => false }].compact
elsif place =~ /^file:\/\/(.*)/
['>= 0', { :path => File.expand_path($1), :require => false }]
else
[place, { :require => false }]
end
end

group :development, :unit_tests do
gem 'rake', :require => false
gem 'rspec-puppet', :require => false
gem 'rspec-core', '3.1.7', :require => false
gem 'rspec-puppet', '~> 1.0', :require => false
gem 'puppetlabs_spec_helper', :require => false
gem 'serverspec', :require => false
gem 'puppet-lint', '0.3.2', :require => false
gem 'beaker', :require => false
gem 'beaker-rspec', :require => false
gem 'pry', :require => false
gem 'puppet-lint', :require => false
gem 'simplecov', :require => false
gem 'puppet_facts', :require => false
gem 'json', :require => false
end

beaker_rspec_version = ENV['BEAKER_RSPEC_VERSION']
group :system_tests do
if beaker_rspec_version
gem 'beaker-rspec', *location_for(beaker_rspec_version)
else
gem 'beaker-rspec', :require => false
end
gem 'serverspec', :require => false
end

if facterversion = ENV['FACTER_GEM_VERSION']
gem 'facter', facterversion, :require => false
gem 'facter', *location_for(facterversion)
else
gem 'facter', :require => false
end

if puppetversion = ENV['PUPPET_GEM_VERSION']
gem 'puppet', puppetversion, :require => false
gem 'puppet', *location_for(puppetversion)
else
gem 'puppet', :require => false
end
Expand Down
10 changes: 8 additions & 2 deletions concat/README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
#Concat

[![Build Status](https://travis-ci.org/puppetlabs/puppetlabs-concat.png?branch=master)](https://travis-ci.org/puppetlabs/puppetlabs-concat)

####Table of Contents

1. [Overview](#overview)
Expand Down Expand Up @@ -216,6 +214,14 @@ Ensure there's a newline at the end of the fragments.
- ensure_newline => true
- ensure_newline => false

#####`validate_cmd`
Ensure the destination file passes the following validation command.
Only supported on Puppet >= 3.5.0.

######Example
- validate_cmd => '/usr/sbin/apache2 -t -f %'
- validate_cmd => '/usr/sbin/visudo -c -f %'

####concat::fragment

#####`target`
Expand Down
2 changes: 1 addition & 1 deletion concat/Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@ require 'puppetlabs_spec_helper/rake_tasks'
require 'puppet-lint/tasks/puppet-lint'

PuppetLint.configuration.fail_on_warnings
PuppetLint.configuration.send('relative')
PuppetLint.configuration.send('disable_80chars')
PuppetLint.configuration.send('disable_class_inherits_from_params_class')
PuppetLint.configuration.send('disable_class_parameter_defaults')
PuppetLint.configuration.send('disable_documentation')
PuppetLint.configuration.send('disable_single_quote_string_with_variables')
PuppetLint.configuration.ignore_paths = ["spec/**/*.pp", "pkg/**/*.pp"]
25 changes: 14 additions & 11 deletions concat/files/concatfragments.rb
Original file line number Diff line number Diff line change
Expand Up @@ -40,13 +40,13 @@
require 'fileutils'

settings = {
:outfile => "",
:workdir => "",
:test => false,
:force => false,
:warn => "",
:sortarg => "",
:newline => false
:outfile => "",
:workdir => "",
:test => false,
:force => false,
:warn => "",
:sortarg => "",
:newline => false
}

OptionParser.new do |opts|
Expand Down Expand Up @@ -116,15 +116,18 @@
Dir.chdir(settings[:workdir])

if settings[:warn].empty?
File.open("fragments.concat", 'w') {|f| f.write("") }
File.open("fragments.concat", 'w') { |f| f.write("") }
else
File.open("fragments.concat", 'w') {|f| f.write("#{settings[:warn]}\n") }
File.open("fragments.concat", 'w') { |f| f.write("#{settings[:warn]}\n") }
end

# find all the files in the fragments directory, sort them numerically and concat to fragments.concat in the working dir
open('fragments.concat', 'a') do |f|
Dir.entries("fragments").sort.each{ |entry|

fragments = Dir.entries("fragments").sort
if settings[:sortarg] == '-n'
fragments = fragments.sort_by { |v| v.split('_').map(&:to_i) }
end
fragments.each { |entry|
if File.file?(File.join("fragments", entry))
f << File.read(File.join("fragments", entry))

Expand Down

0 comments on commit a63e8a9

Please sign in to comment.