Commit graph

733 commits

Author SHA1 Message Date
Jeff McCune
06952967bf Merge branch '4.x'
* 4.x:
  (#14670) Fixup file_line autorequire specs
  (#14670) autorequire a file_line resource's path
2012-11-26 11:41:34 -08:00
Jeff McCune
9224e37076 Merge branch '3.x' into 4.x
* 3.x:
  (#14670) Fixup file_line autorequire specs
  (#14670) autorequire a file_line resource's path
2012-11-26 11:41:25 -08:00
Jeff McCune
0648148bfb Merge branch '2.x' into 3.x
* 2.x:
  (#14670) Fixup file_line autorequire specs
  (#14670) autorequire a file_line resource's path
2012-11-26 11:41:01 -08:00
Jeff McCune
b55994b2be Merge branch 'fun/2.x/14670_file_line_autorequire' into 2.x
* fun/2.x/14670_file_line_autorequire:
  (#14670) Fixup file_line autorequire specs
  (#14670) autorequire a file_line resource's path
2012-11-26 11:39:26 -08:00
Jeff McCune
d8cde95295 (#14670) Fixup file_line autorequire specs
Without this patch applied the file_line autorequire examples are
failing.  This is a problem because the failures are false positives and
should be passing given the implementation.

This patch fixes the problem by changing the examples to directly test
the existence of the relationship by finding it in the list of
autorequire relationships.
2012-11-26 11:37:08 -08:00
Peter Meier
dfcee63afb (#14670) autorequire a file_line resource's path
If we manage a file we edit with file_line, it should be autorequired by
file_line.  Without this patch applied the relationship is not
automatically setup and the user is forced to manually manage the
relationship.
2012-11-26 10:35:18 -08:00
Jeff McCune
32419e77ed Merge branch '4.x'
* 4.x:
  Add join_keys_to_values function
2012-11-20 16:17:08 -05:00
Jeff McCune
8647691c3a Merge branch '3.x' into 4.x
* 3.x:
  Add join_keys_to_values function
2012-11-20 16:16:59 -05:00
Jeff McCune
ad262b56a4 Merge branch '2.x' into 3.x
* 2.x:
  Add join_keys_to_values function
2012-11-20 16:16:50 -05:00
Jeff McCune
6c104e5e3a Merge branch 'lifton-feature/2.x/join_keys_to_values_function' into 2.x
* lifton-feature/2.x/join_keys_to_values_function:
  Add join_keys_to_values function
2012-11-20 16:16:37 -05:00
Joshua Harlan Lifton
ee0f2b307d Add join_keys_to_values function
This commit adds a function that joins each of a hash's keys with that
key's corresponding value, separated by a separator string. The
arguments are a hash and separator string. The return value is an
array of joined key/value pairs.
2012-11-20 16:16:03 -05:00
Jeff McCune
326a13908b Merge branch 'jfryman-master'
* jfryman-master:
  puppet-lint cleanup
2012-11-19 11:23:50 -05:00
Jeff McCune
f40bb1e288 Merge branch '4.x'
* 4.x:
  Extend delete function for strings and hashes
  Fixed typo
2012-11-19 08:45:48 -05:00
Jeff McCune
eba7d6ac79 Merge branch '3.x' into 4.x
* 3.x:
  Extend delete function for strings and hashes
  Fixed typo
2012-11-19 08:45:39 -05:00
Jeff McCune
824ea6d49f Merge branch '2.x' into 3.x
* 2.x:
  Extend delete function for strings and hashes
  Fixed typo
2012-11-19 08:45:31 -05:00
Jeff McCune
6c36b494a0 Merge branch 'lifton-feature/2.x/extend_delete_function' into 2.x
* lifton-feature/2.x/extend_delete_function:
  Extend delete function for strings and hashes
  Fixed typo
2012-11-19 08:45:18 -05:00
Joshua Harlan Lifton
7322e4dc2f Extend delete function for strings and hashes
Previous to this commit, the delete function only acted on
arrays. This commit adds the same functionality for hashes and strings
in the obvious way: delete(h, k) would delete the k key from the h
hash and delete(s, sub) would delete all instances of the sub
substring from the s string.
2012-11-19 08:44:44 -05:00
Joshua Harlan Lifton
0798059361 Fixed typo 2012-11-19 08:44:44 -05:00
James Fryman
88acc52393 puppet-lint cleanup 2012-11-15 10:38:03 -06:00
Jeff McCune
fda49d4ab3 Merge branch '4.x'
* 4.x:
  Add the pick() function
2012-11-15 08:57:40 -05:00
Jeff McCune
598ef3a62c Merge branch '3.x' into 4.x
* 3.x:
  Add the pick() function
2012-11-15 08:57:28 -05:00
Jeff McCune
5353cd77b7 Merge branch '2.x' into 3.x
* 2.x:
  Add the pick() function
2012-11-15 08:57:21 -05:00
Jeff McCune
43dd606982 Merge branch 'feature/2.x/pick' into 2.x
* feature/2.x/pick:
  Add the pick() function
2012-11-15 08:56:52 -05:00
Gary Larizza
ba6dd13990 Add the pick() function
This function is similar to a coalesce function in SQL in that it will
return
the first value in a list of values that is not undefined or an empty
string
(two things in Puppet that will return a boolean false value).
Typically,
this function is used to check for a value in the Puppet
Dashboard/Enterprise
Console, and failover to a default value like the following:

  $real_jenkins_version = pick($::jenkins_version, '1.449')

The value of $real_jenkins_version will first look for a top-scope
variable
called 'jenkins_version' (note that parameters set in the Puppet
Dashboard/
Enterprise Console are brought into Puppet as top-scope variables), and,
failing that, will use a default value of 1.449.
2012-11-15 08:52:19 -05:00
Jeff McCune
747dcc6fc7 Merge branch '4.x'
* 4.x:
  (#13974) Add predicate functions for interface facts
2012-11-07 14:03:44 -08:00
Jeff McCune
f9616ef72f Merge branch '3.x' into 4.x
* 3.x:
  (#13974) Add predicate functions for interface facts
2012-11-07 14:03:31 -08:00
Jeff McCune
b97e053cad Merge branch '2.x' into 3.x
* 2.x:
  (#13974) Add predicate functions for interface facts
2012-11-07 14:03:22 -08:00
Jeff McCune
f8635584a8 Merge branch 'add/2.x/13974-has_interface_with' into 2.x
* add/2.x/13974-has_interface_with:
  (#13974) Add predicate functions for interface facts
2012-11-07 14:03:08 -08:00
Wil Cooley
f8194176dc (#13974) Add predicate functions for interface facts
If one wishes to test if a host has a particular IP address (such as a floating
virtual address) or has an interface on a particular network (such as a
secondary management network), the facts that provide this information are
difficult to use within Puppet.

This patch addresses these needs by implementing functions
‘has_ip_address(value)’ and ‘has_ip_network(value)’. These functions look
through all interfaces for ipaddress_<interface> and network_<interface>
(respectively) having the requested <value>.

These functions are implemented on top of a lower-level predicate
function, ‘has_interface_with(kind, value)’, which iterates through the
interfaces in the ‘interfaces’ fact and checks the facts <kind>_<interface>
looking for <value>.

Additionally, the existence of a particular named interface can be checked for
by calling with only a single argument: has_interface_with(interface).

A Boolean is returned in all cases.
2012-11-07 14:00:44 -08:00
Jeff McCune
34b9cb8b94 Merge branch '4.x'
* 4.x:
  Add function, uriescape, to URI.escape strings. Redmine #17459
  Add function, uriescape, to URI.escape strings. Redmine #17459
  Add function, uriescape, to URI.escape strings. Redmine #17459
  Update CHANGELOG, Modulefile for 3.1.1
2012-11-07 09:44:51 -08:00
Jeff McCune
0b3e8f59a9 Merge branch '3.x' into 4.x
* 3.x:
  Add function, uriescape, to URI.escape strings. Redmine #17459
  Add function, uriescape, to URI.escape strings. Redmine #17459
  Update CHANGELOG, Modulefile for 3.1.1
2012-11-07 09:44:35 -08:00
Jeff McCune
20f4811a9e Merge branch 'add/4.x/joejulian-add_uriescape' into 4.x
* add/4.x/joejulian-add_uriescape:
  Add function, uriescape, to URI.escape strings. Redmine #17459
2012-11-07 09:44:31 -08:00
Jeff McCune
be71219f12 Merge branch '2.x' into 3.x
* 2.x:
  Add function, uriescape, to URI.escape strings. Redmine #17459
2012-11-07 09:43:52 -08:00
Jeff McCune
348f1300c0 Merge branch 'add/3.x/joejulian-add_uriescape' into 3.x
* add/3.x/joejulian-add_uriescape:
  Add function, uriescape, to URI.escape strings. Redmine #17459
2012-11-07 09:43:47 -08:00
Jeff McCune
bf66ded063 Merge branch 'add/2.x/joejulian-add_uriescape' into 2.x
* add/2.x/joejulian-add_uriescape:
  Add function, uriescape, to URI.escape strings. Redmine #17459
2012-11-07 09:40:37 -08:00
Joe Julian
fd52b8d88a Add function, uriescape, to URI.escape strings. Redmine #17459 2012-11-07 09:36:54 -08:00
Joe Julian
2fc85d25d2 Add function, uriescape, to URI.escape strings. Redmine #17459 2012-11-07 09:36:54 -08:00
Joe Julian
70f4a0e9ed Add function, uriescape, to URI.escape strings. Redmine #17459 2012-11-07 09:36:54 -08:00
Jeff McCune
6f0c1e248c Merge branch '3.1.x' into 3.x
* 3.1.x:
  Update CHANGELOG, Modulefile for 3.1.1
2012-10-25 16:06:29 -07:00
Jeff McCune
a3c600d5f2 Update CHANGELOG, Modulefile for 3.1.1 2012-10-25 16:06:25 -07:00
Jeff McCune
23cf7d0ac1 Merge branch '4.x'
* 4.x:
  Update Modulefile, CHANGELOG for 2.5.1
2012-10-25 15:55:11 -07:00
Jeff McCune
65d9b10876 Merge branch '3.x' into 4.x
* 3.x:
  Update Modulefile, CHANGELOG for 2.5.1
2012-10-25 15:55:04 -07:00
Jeff McCune
f4c8c6b8de Merge branch '2.x' into 3.x
* 2.x:
  Update Modulefile, CHANGELOG for 2.5.1

Conflicts:
	CHANGELOG
	Modulefile
2012-10-25 15:54:51 -07:00
Jeff McCune
cc670fb3b1 Merge branch '2.5.x' into 2.x
* 2.5.x:
  Update Modulefile, CHANGELOG for 2.5.1
2012-10-25 15:53:40 -07:00
Jeff McCune
1bb4c7a79e Update Modulefile, CHANGELOG for 2.5.1 2012-10-25 15:51:23 -07:00
Jeff McCune
aa22cded08 Merge branch '4.x'
* 4.x:
  Revert "Revert "Merge branch '2.5.x' into 3.0.x""
  Revert "Merge branch '2.5.x' into 3.0.x"
  (maint) Fix spec failures resulting from Facter API changes
2012-10-25 15:48:01 -07:00
Jeff McCune
18212dca01 Merge branch '3.x' into 4.x
* 3.x:
  Revert "Revert "Merge branch '2.5.x' into 3.0.x""
  Revert "Merge branch '2.5.x' into 3.0.x"
  (maint) Fix spec failures resulting from Facter API changes
2012-10-25 15:47:53 -07:00
Jeff McCune
9cc15a650a Merge branch '3.1.x' into 3.x
* 3.1.x:
  Revert "Revert "Merge branch '2.5.x' into 3.0.x""
  Revert "Merge branch '2.5.x' into 3.0.x"
  (maint) Fix spec failures resulting from Facter API changes
2012-10-25 15:47:48 -07:00
Jeff McCune
614b3fbf6c Merge branch '2.5.x' into 3.1.x
* 2.5.x:
  (maint) Fix spec failures resulting from Facter API changes
2012-10-25 15:47:25 -07:00
Jeff McCune
43729e6ea9 Revert "Revert "Merge branch '2.5.x' into 3.0.x""
This reverts commit 9e8c60a8b7.

This was an error on my part.  3.1.x descends from 3.0.x _and_ 2.5.x, but 3.0.x does
not descend from 2.5.x.  I should not have merged 2.5.x into 3.0.x,
instead I should have merged 2.5.x into 3.1.x skipping over the 3.0.x
merge up.

I'm slowly starting to understand the implications of semver on our
branching strategy...  =)
2012-10-25 15:44:14 -07:00