Commit graph

7189 commits

Author SHA1 Message Date
Brian Coca
7c690f04e2 task get_path returns empty string when not in play 2016-06-29 10:50:36 -04:00
Peter Sprygada
216a845244 Merge pull request #16486 from privateip/netcmd
removes dependency on collections module from netcmd
2016-06-28 17:46:32 -07:00
Peter Sprygada
9b40e1106e removes dependency on collections module from netcmd
This change removes the dependency on collections so netcmd is
compatable with python versions prior to py2.7
2016-06-28 17:13:13 -07:00
Matt Clay
8f1b487141 Handle repeat includes in junit callback. (#16484) 2016-06-28 15:55:46 -07:00
Toshio Kuratomi
405dca1abe Update submodule refs 2016-06-28 14:53:46 -07:00
Brian Coca
2bb7feec6d Search path (#16387)
* smarter function to figure out relative paths

takes list of paths in order of relevance to current task
and does the dwim magic on them

* shared function for action plugins using new dwim

unify path construction and error info/messaging
made include and role non exclusive
corrected order and now smarter about tasks
includes inside roles are currently broken as they don't provide the correct role data
make dirname full match to avoid corner cases

* migrated action plugins to new dwim function

reported plugins to use exceptions instead of info

* clarified needle
2016-06-28 17:23:30 -04:00
Brian Coca
d843e5a79d removed unused boolean 2016-06-28 15:25:18 -04:00
Brian Coca
9abdb1bb7c added skipped_reason for verbosity not met
fixes http://github.com/ansible/ansible-modules-core/issues/4062
2016-06-28 15:24:59 -04:00
jctanner
4ba60d00c8 Refactor the parameter splitting in ini lookup to handle more path formats (#16477)
Refactor the parameter splitting in ini lookup to handle more path formats.

Fixes #16468
2016-06-28 13:24:57 -04:00
Brian Coca
3afe50dfe2 push unicode handling into unfrack 2016-06-28 10:57:41 -04:00
Brian Coca
bae988ee9b fix path utils 2016-06-28 10:38:34 -04:00
Lars Fredriksen
4b5203c5fb add holders to partitions (#16446)
* add holders to partitions

* make holder gathering a function
2016-06-28 09:44:51 -04:00
James Cammarata
af249b83e6 Don't modify the original task ds when preprocessing data
In the case of using YAML anchors/aliases, YAML actually uses references
to the duplicated object so any modifications to the original impacts
later uses of the object.

Fixes #13575
2016-06-28 03:07:59 -05:00
Pilou
b361bf90d7 Lookup password omit salt (#16361)
* Lookup unencrypted password must not include salt
* Integration test lookup: remove previous directory
* Test that lookup password doesn't return salt
* Lookup password: test behavior with empty encrypt parameter

Closes #16189
2016-06-27 10:44:25 -07:00
nitzmahone
60a8af95a5 bump core submodule ref 2016-06-27 09:00:25 -07:00
Brian Coca
1b7b1ca15e if seconds are specified, min is 1 2016-06-27 09:36:15 -04:00
Peter Sprygada
d83962d3f5 Merge pull request #15992 from ogenstad/asa
Module util, template action and doc fragment for Cisco ASA
2016-06-27 06:32:12 -07:00
Matt Clay
c2a5cb6174 Fix junit callback plugin for Python 2.6. (#16440) 2016-06-24 14:22:27 -07:00
James Cammarata
04fca42b62 Fixing issues with getattr caused by 5a3493b 2016-06-24 15:43:03 -05:00
Toshio Kuratomi
9330edd6b9 Update submodule refs 2016-06-24 09:01:40 -07:00
Peter Sprygada
32b605f603 Merge pull request #16422 from privateip/network
bug fix changes Config class in network to only raise exceptions
2016-06-23 16:15:20 -07:00
Peter Sprygada
02902325b4 Merge pull request #16424 from privateip/vyos
initial commit of vyos shared module with Cli transport
2016-06-23 16:15:07 -07:00
James Cammarata
948682dbe2 Fix off-by-one error with retries
Fixes #16408
2016-06-23 18:07:11 -05:00
James Cammarata
3e4755f7e4 Remove unnecessary role initialization and lookup stuff
* Remove unnecessary copying of values from parents to role deps, as
  this can cause problems when roles have multiple parents (or the same
  parents with different params speficied through deps)
* Since we're already checking the dep chain in the block for role
  things (which every task in a role should have), it is not necessary
  to check the role directly in case it improperly grabs something

Fixes #14438
2016-06-23 17:00:01 -05:00
nitzmahone
ac04ffb9b1 apply @zazard's fix to parent attribute lookup 2016-06-23 14:11:07 -07:00
Peter Sprygada
77922f82e2 initial commit of vyos shared module with Cli transport
This adds support for the VyOS network operating system using the
Cli transport.   This module will simplify building VyOS based
modules in Ansible
2016-06-23 12:27:33 -07:00
James Cammarata
c24c0f5f6b Properly wrap objects using json default encoder
Our custom encoder for the to_json filter was simply returning the
object if it was not a HostVars object, leading in some cases to a
TypeError when the data contained an undefined variable. This lead
to an odd error message being propagated up, so we now properly catch
this as an undefined variable error.

Fixes #15610
2016-06-23 09:19:32 -05:00
w1r0x
7d24e6e95c Fixes #12309 (#14121) 2016-06-23 09:02:34 -04:00
James Cammarata
3ea3fa8d46 Merge pull request #14639 from ivovangeel/find_mount_point-bug
Fixed bug in find_mount_point function
2016-06-22 22:38:54 -05:00
nitzmahone
5f9ca67685 bump extras submodule ref for test failures 2016-06-22 17:27:16 -07:00
nitzmahone
76633ddc4c bump submodule refs 2016-06-22 17:21:54 -07:00
James Cammarata
7c27f72515 Merge pull request #14356 from mludvig/session_token
Add support for AWS_SESSION_TOKEN environment variable. (trivial patch)
2016-06-22 18:51:09 -05:00
Peter Sprygada
107c13759e changes Config class in network to only raise exceptions
The Config class should not call fail_json but simply raise exceptions
and allow the implementor to handle the exception
2016-06-22 09:22:50 -05:00
Toshio Kuratomi
39c543e356 Use find -exec + so that failures will be visible in find's exit code (#16389)
Fixes #16385
2016-06-22 05:42:37 -07:00
James Cammarata
4c1601e9f2 Take previously failed/unreachable hosts into account when checking the batch
Again, as we're carrying failed/unreachable hosts forward from play to play via
internal structures, we need to remember which ones had previously failed so that
unrelated host failures don't inflate the numbers for a given serial batch in the
PlaybookExecutor causing a premature exit.

Fixes #16364
2016-06-21 16:47:38 -05:00
James Cammarata
aefa12a20f Merge pull request #13709 from traveloka/credstash-support-encr-context
Make credstash lookup plugin support encryption contexts
2016-06-21 11:00:43 -05:00
James Cammarata
15e648dd94 Fix handler listeners as a list
The listen statement on handlers should have supported a list, however
it was broken in the revision of the pub/sub feature based on the handler
revamp. This patch corrects the bug, so this works again:

- name: some handler
  ...
  listen:
  - some target
  - another target

Fixes #16378
2016-06-21 10:00:10 -05:00
James Tanner
b1d32e6e32 Update submodule refs 2016-06-20 18:08:20 -04:00
nitzmahone
2bf9f593b5 bump submodule refs 2016-06-20 13:09:57 -07:00
James Cammarata
96a96b0e97 Merge pull request #16360 from agaffney/old_style_module_args_quoting
Fix quoting of args for old-style modules
2016-06-20 12:42:47 -05:00
Nathaniel Case
5dccff29bf Network Module: EOS (#16158)
* add new module network

* move EOS to NetworkModule

* shell.py Python 3.x compatibility

* implements the Command class through the connection for eos

This implements a new Command class that specifies the cli command
and output format.  This removes the need to batch commands through
the connection

* initial add of netcmd module
2016-06-20 12:11:48 -04:00
James Cammarata
17447ff035 Fixing typo in base strategy code from handler listen feature merge 2016-06-20 09:47:43 -05:00
James Cammarata
ca6ee4c789 FEATURE: handler listeners
Fixes ansible/proposals#8
2016-06-20 09:30:20 -05:00
James Cammarata
8218591fec Track notified handlers by object rather than simply their name
Due to the fact that roles may be instantiated with different sets of
params (multiple inclusions of the same role or via role dependencies),
simply tracking notified handlers by name does not work. This patch
changes the way we track handler notifications by using the handler
object itself instead of just the name, allowing for multiple internal
instances. Normally this would be bad, but we also modify the way we
search for handlers by first looking at the notifying tasks dependency
chain (ensuring that roles find their own handlers first) and then at
the main list of handlers, using the first match it finds.

This patch also modifies the way we setup the internal list of handlers,
which should allow us to correctly identify if a notified handler exists
more easily.

Fixes #15084
2016-06-20 09:30:20 -05:00
Andrew Gaffney
a64f7fd602 Fix quoting of args for old-style modules
This removes the extra layer of quotes around values in the 'args' file.
These quotes were there before the pipes.quote() call was added, but
were not removed, resulting in too much quoting.
2016-06-19 19:21:25 +00:00
jctanner
1db02dfb71 If decryption of a vaulted file failed, include the filename in the error. (#16329)
Fixes #16327
2016-06-18 09:30:08 -04:00
James Cammarata
8ee851cd95 Merge pull request #13460 from yesbox/devel
Adds support for converting a MAC address to an integer
2016-06-18 08:16:12 -05:00
James Cammarata
4bc85e150a Merge pull request #12807 from Lujeni/devel
Ansible-galaxy requirements support a include directive
2016-06-18 07:50:59 -05:00
James Cammarata
20754c1094 Allow groups to be specified using YAML list syntax for add_host
Fixes #12622
2016-06-18 07:47:10 -05:00
Zempashi
af150ea43a Fix linux 'ip' stdout parsing. (#16170)
With network-manager in debian (stretch) and openvpn connection enabled
the output for ipv6 is different and include a 'peer' keyword.

Fixes #15448
2016-06-17 17:10:45 -04:00