Toshio Kuratomi
7334389de6
Merge pull request #12930 from ansible/dict-key-overwrite-warning
...
Break apart a looped dependency to show a warning when parsing playbooks
2015-10-27 12:44:01 -07:00
Toshio Kuratomi
4203850d1a
Break apart a looped dependency to show a warning when parsing playbooks
...
Display a warning when a dict key is overwritten by pyyaml
Fixes #12888
2015-10-27 12:39:42 -07:00
James Cammarata
3fc2209ca0
Fixing retry/until logic and default value for retries
...
Fixes #12928
Fixes #12929
2015-10-27 15:37:48 -04:00
Brian Coca
8ce864db6f
sanatize results
2015-10-24 15:23:12 -04:00
Toshio Kuratomi
92dd563a75
Fix invocation from bad merge and note where it would need to go to keep
...
it out of registered vars as well.
2015-10-24 07:29:42 -07:00
Brian Coca
5017a96948
Revert "make callbacks declare needing whitelisting"
...
another premature merge
This reverts commit df8ff85787
.
2015-10-22 16:34:51 -04:00
James Cammarata
86de1429e5
Cleaning up FIXMEs
2015-10-22 16:03:50 -04:00
Brian Coca
df8ff85787
make callbacks declare needing whitelisting
...
this will allow for custom or v1 callbacks locally loaded to automatically be triggered as they were in 1.x
2015-10-22 12:30:23 -04:00
Brian Coca
c267c23020
make callbacks declare needing whitelisting
...
this will allow for custom or v1 callbacks locally loaded to automatically be triggered as they were in 1.x
2015-10-22 08:27:32 -04:00
Brian Coca
fc3a44485b
skip errors on conditional if task is include
...
fixes #12843
2015-10-22 07:50:43 -04:00
James Cammarata
ec56b29ba4
Fix setting of interpreter values for delegated hosts
...
Fixes #12772
2015-10-21 11:05:45 -04:00
Victor Salgado
c5c5f3bf7a
Revert back to copying self._task.args
2015-10-20 16:21:25 -02:00
Victor Salgado
0e671baa33
Fix typo
2015-10-20 16:18:01 -02:00
James Cammarata
1fa975d81a
Simplify group_by by removing BYPASS_HOST_LOOP from the action
...
Fixes #12825
2015-10-19 14:57:07 -04:00
Toshio Kuratomi
a526eae543
Clean up a few more pyflakes warnings
2015-10-19 11:20:21 -07:00
James Cammarata
892d9b8dfb
Move post_validate for tasks after checking for an include
...
Simplifies logic and prevents us from accidentally post_validating
an include that would otherwise be skipped due to tags causing a
problem because of potentially missing variables.
Fixes #12793
2015-10-19 13:42:17 -04:00
James Cammarata
a88c59f451
Reset basedir for plays that are not from a PlaybookInclude
...
Fixes #12524 (again)
2015-10-17 12:44:28 -04:00
Toshio Kuratomi
baa309309d
Bundle a new version of python-six for compatibility along with some code to make it easy for distributions to override the bunndled copy if they have a new enough version.
2015-10-16 08:21:28 -07:00
Marius Gedminas
4fb6f62f1b
Fix Unexpected Exception: global name 'os' is not defined
...
I inadvertently introduced it in
ca826508d9
and didn't notice, because
there are no unit tests for playbook_executor.py. Sorry!
(The "from ansible.errors import *" was used *only* to get the 'os'
module, which makes go "what?")
2015-10-15 10:41:00 +03:00
Marius Gedminas
9ba6c087d3
Python 3: there's no basestring
2015-10-13 09:56:12 +03:00
James Cammarata
82e76e42e5
Tweak to the way serial percentages are handled
2015-10-12 09:00:43 -04:00
Toshio Kuratomi
01ba2e94c0
Wait until later to convert to byte strings for output
...
Also some pre-emptive python3 compat and a code simplification
2015-10-08 08:22:17 -07:00
Brian Coca
76feba00c4
avoid callbacks during syntax check and listing
...
fixes #12682
2015-10-08 10:15:48 -04:00
James Cammarata
d91b3c6b9d
Make sure magic variables are available when templating vars_files
...
Also does some reorganization/cleanup on the magic vars/delegated
variable generation portions of VariableManager to make the above
possible.
Fixes #12633
2015-10-05 16:32:58 -04:00
Brian Coca
e2ae3215f6
corrected no_log for items and skipped tasks
...
corrected output from default callback
added new tests for no_log loops
updated makefile test to check for both positive and negative occurrences of no_log
2015-10-02 14:35:33 -04:00
Brian Coca
ba4afcbbb6
added no_log to results
...
normalized outputs to use display class
cleaned up unused imports
2015-10-02 09:11:41 -04:00
James Cammarata
8ef78b1cf8
Fixing accelerated connection plugin
2015-10-02 00:50:02 -04:00
James Cammarata
deff045aa9
Fix bug caused by options not having start_at_task when used through adhoc
...
Fixes #12590
2015-10-01 10:09:58 -04:00
James Cammarata
dcb8caf9e8
Remember if we already skipped tasks via --start-at-task
...
Fixes #12482
2015-09-30 14:12:38 -04:00
James Cammarata
a3e913da62
Don't assume handlers exist in the same role (if any)
...
Fixes #12536
2015-09-29 14:52:43 -04:00
James Cammarata
ffdba96668
Save the included directory for playbook includes for use as the basedir
...
Fixes #12524
2015-09-29 00:28:45 -04:00
James Cammarata
31d5f88a1d
Use the task loop to calculate multiple delegated hosts
...
Due to the way we're now calculating delegate_to, if that value is based
on a loop variable ('item') we need to calculate all of the possible
delegated_to variables for that loop.
Fixes #12499
2015-09-25 01:41:09 -04:00
Brian Coca
de18bcb95f
correct typo on error reporting
...
fixes #12495
2015-09-23 10:11:52 -04:00
Toshio Kuratomi
2a614c1c0f
Close module file once we're done reading from it
2015-09-21 01:46:29 -07:00
James Cammarata
88e1aa94fa
Add play context vars to list of variables before post validation
...
Fixes #12437
2015-09-19 21:51:24 -04:00
James Cammarata
1f5584aa5b
Refactoring delegate_to code
...
Now, instead of relying on hostvars on the executor side, we compile
the vars for the delegated to host in a special internal variable and
have the PlayContext object look for things there when applying task/
var overrides, which is much cleaner and takes advantage of the code
already dealing with all of the magic variable variations.
Fixes #12127
Fixes #12079
2015-09-18 15:25:10 -04:00
James Cammarata
fa69e8ebb8
Fixing some bugs in _compute_delegate() in TaskExecutor
...
* Clearing interpreter settings from variables, so those set for the
original host aren't incorrectly applied to the delegated to host
* Fixed incorrect string for remote user in delegated hosts hostvars
* Properly looking for multiple possiblities in the delegated-to hosts
hostvars (ansible_ssh_host vs. ansible_host)
2015-09-18 15:25:10 -04:00
James Cammarata
cc6627cdd6
Remove custom json encoder cleaner and strip proxy var stuff out before encoding
...
Fixes #12349
2015-09-17 16:04:47 -04:00
James Cammarata
bde5ed9672
Catch worker errors that may be subclassed on others that lead to incorrect exits
2015-09-17 14:46:53 -04:00
Abhijit Menon-Sen
575a8b8c77
Merge Host.ipv[46]_address into .address
...
The earlier distinction was never used; .ipv6_address was always a copy
of .ipv4_address, and the latter was always used to set the remote_addr
field in the PlayContext.
Also uses the canonical ansible_host/ansible_port names when setting the
address and port from variables.
2015-09-17 23:03:48 +05:30
James Cammarata
a7e1113b26
Removing FIXME comment which is no longer required
2015-09-15 14:47:49 -04:00
James Cammarata
60c139e482
Fix logic for changed/failed_when + retry/until loops
...
Fixes #11809
2015-09-15 13:37:35 -04:00
James Cammarata
8e664ad226
Fix delegate_to localhost vs. 127.0.0.1 (and ::1)
2015-09-15 13:08:54 -04:00
James Cammarata
4156bcedf5
Fix typo in 049a48f
2015-09-11 15:54:24 -04:00
Abhijit Menon-Sen
049a48f3d3
Test state.tasks_child_state before dereferencing
...
I hit a traceback in the FAILED_TASKS case, but it seemed prudent to add
guards in the other similar branches.
2015-09-11 21:59:08 +05:30
Thomas Quinot
0bc9223826
Test for Python must be against basename of interpreter
...
Followup on issue #12076
2015-09-11 13:29:34 +02:00
James Cammarata
441a8af671
Merge pull request #12267 from h-hirokawa/add_replacer_jsonargs
...
Add the new module replacer <<INCLUDE_ANSIBLE_MODULE_JSON_ARGS>>.
2015-09-11 02:44:50 -04:00
James Cammarata
0c5bbe3c32
Use the original (un-templated) args for include params
...
Fixes #12314
2015-09-11 00:53:27 -04:00
James Cammarata
aa3b290efd
Fix indent on line in playbook executor
2015-09-09 18:10:38 -04:00
James Cammarata
e81947c3b4
Fix vars_prompt short form support (and mark deprecated)
2015-09-09 17:52:44 -04:00