Commit Graph

277 Commits (182c6603e77b423bba2dce53bf2994bc4e728542)

Author SHA1 Message Date
Michael DeHaan 8c4161d4a1 Merge branch 'retf_py' of git://github.com/berendt/ansible into devel
Conflicts:
	lib/ansible/inventory/vars_plugins/group_vars.py
	plugins/callbacks/mail.py
2014-08-08 12:17:37 -04:00
James Cammarata a45c3b84f3 Avoid templating raw lookup strings 2014-08-06 13:25:14 -05:00
James Cammarata 9c1a89ff4e Merge branch 'patch-1' of https://github.com/debfx/ansible into debfx-patch-1 2014-07-31 11:41:21 -05:00
Michael DeHaan 645ab7baff Merge pull request #7950 from mesk41in/devel
Fix unsupported regexp parameter in assemble
2014-07-28 12:01:12 -04:00
someda 1b1d5d0d3d fix an issue that copying directory will fail when trying to change file attributes and the target file already exists on remote
- the issue was introduced by the commit 84759faa09
2014-07-24 14:03:36 +09:00
Benno Joy ac85d8444b fix for unarchive 8257 2014-07-23 14:50:16 +00:00
James Cammarata 84759faa09 Security fixes:
* Strip lookup calls out of inventory variables and clean unsafe data
  returned from lookup plugins (CVE-2014-4966)
* Make sure vars don't insert extra parameters into module args and prevent
  duplicate params from superseding previous params (CVE-2014-4967)
2014-07-21 11:20:49 -05:00
Serge van Ginderachter 4e9a253bef Load existing group_vars file for new group_by group
if it was not loaded yet, which happens if that group
didn't exist yet in the inventory.

fixes #8159
2014-07-16 21:16:27 +02:00
Felix Geyer 0ebd19e97b Fix regression: Sanitize sudo success_key from stdout
Commit 7e3dd10 caused a regression with sanitizing the sudo success_key from stdout.
There is no newline in front of SUDO-SUCCESS when using sudo.
This change adapts the regex to make the line break optional.

Tested on Ubuntu 14.04.
2014-07-16 18:14:35 +02:00
James Cammarata b8ac094eaa Tweak to only show msg on assert failure if set 2014-07-08 14:05:24 -05:00
James Cammarata 16332b8488 Merge branch 'assert-with-msg' of https://github.com/darkk/ansible into darkk-assert-with-msg 2014-07-08 13:56:08 -05:00
Leonid Evdokimov d94395f48c assert: add optional `msg` argument
Sample playbook when it may be useful:
```
- uri: return_content=yes url={{ api_base }}/action/{{ inventory_hostname }}
  register: output
- assert:
    msg: '{{ output.json | to_nice_json }}'
    that:
      - output.json.foo != "bar"
      - output.json.boo == 42
```
2014-07-07 19:05:17 +04:00
James Cammarata ff04b2b532 Allow empty yaml vars files
Fixes #7843
2014-07-04 23:10:32 -05:00
mesk41in 488aec3936 Fix unsupported regexp parameter in assemble 2014-06-27 13:54:59 +04:00
Paul Sokolovsky f8bf9cdeec Handle TemplateNotFound to render more helpful error message.
At the point the exception is handled, it is likely due to error loading
a sub-template included from main template. Besides file not found, it
can be caused also by include path failing Jinja2 checks. Now, when
rendering the exception from Jinja, it will include exception name. This
will give basic context or *what* the error is.

Fixes #7103
Fixes #7105
2014-06-23 15:02:58 -05:00
Chris Church 615f70e3f4 Fix missing space in script action plugin. 2014-06-19 21:54:21 -05:00
Chris Church 243cd877ae Add integration tests for fetch/slurp, make powershell fetch/slurp work as close as possible to existing fetch/slurp modules. 2014-06-19 14:25:28 -05:00
Chris Church 21ba529fbe Fixes/notes related to slashes in remote paths. 2014-06-19 14:24:14 -05:00
Chris Church f7af29680b Add default license boilerplate, refactor common powershell code, fixes for raw/script modules. 2014-06-19 14:24:13 -05:00
Chris Church 5dcaa30476 Add shell_plugins to abstract shell-specific functions out of runner, add winrm connection plugin, add initial Windows modules. 2014-06-19 14:24:12 -05:00
James Cammarata 188ab7b952 Check groupnames for None as well as an empty string in add_host
Fixes #7585
2014-05-29 11:01:11 -05:00
WAKAYAMA shirou 56880b76bb fix UnicodeEncode error when using pause module with unicode prompt. 2014-05-22 00:21:14 +09:00
James Cammarata 38c2c60849 Do not base synchronize source on the inventory directory
Fixes #7366
2014-05-12 12:02:38 -05:00
James Cammarata 77a47dbb2d Merge pull request #7304 from jimi-c/issue_7296_synchronize_relative_path
Make sure dwim'd relative path ends in a "/" if the original does
2014-05-07 12:58:04 -05:00
Chris Church f9c74d6e57 Add integration tests for group_by module. Fixed bug introduced by ansible/ansible#7273 while also fixing issue described in ansible/ansible#6953 2014-05-06 22:30:37 -04:00
James Cammarata 4d118d1c72 Make sure dwim'd relative path ends in a "/" if the original does
Fixes #7296
2014-05-06 13:54:41 -05:00
James Cammarata fd03cc04e6 Merge branch 'devel' of https://github.com/denisphillips/ansible into denisphillips-devel 2014-05-05 09:22:01 -05:00
Veeti Paananen d6f4d9b76d Fix error handling on missing dest with unarchive
fixes #7107
2014-05-04 18:22:00 +03:00
Denis Phillips cd0134d290 Used module_args passed to function instead of from runner 2014-05-04 08:49:12 -04:00
Christian Berendt 6676720ce5 fixed typos found by RETF rules in PY files
rules are avaialble at https://en.wikipedia.org/wiki/Wikipedia:AutoWikiBrowser/Typos
2014-05-03 18:40:05 +02:00
Jeffrey 'jf' Lim 0bf1a27393 Fix "no_log=True" option for copy module (fixes #7193) 2014-04-30 02:24:16 +08:00
Cédric RICARD b8b0865ec0 Missing 'base64' import 2014-04-25 00:11:27 +02:00
James Cammarata 38b49476f8 Merge branch 'raw-script-su-support' of https://github.com/sivel/ansible into sivel-raw-script-su-support 2014-04-23 10:02:13 -05:00
James Cammarata 40b958e348 Don't turn complex args back into a k=v string for the synchronize module
Fixes #6951
2014-04-14 16:35:16 -05:00
James Tanner 5a65dc3b6a Fixes #6820 fix erroneous missing vault password error when using the template module 2014-04-04 13:06:35 -04:00
James Cammarata 82b24c162e Adding delimiter fixes to action_plugin + fixing local assembling with a delimiter
Also added a new integration test for assemble using local assembly
with a delimiter.
2014-04-03 16:32:35 -05:00
James Tanner 2492c2714a Fixes #5307 set relative paths to the files dir for roles and the inventory dir for non-role tasks 2014-03-31 12:25:40 -04:00
Matt Martz 7e3dd1066c Allow raw and script to support su 2014-03-28 16:46:31 -05:00
Michael DeHaan a062912a1f Merge pull request #6658 from pilou-/fix_fix
'changed' key is not defined when task fails
2014-03-25 11:49:18 -04:00
James Cammarata dc658eaa1c Check to make sure the host is in the inventory vars cache before clearing it
Fixes #6660
2014-03-24 15:59:43 -05:00
Pierre-Louis Bonicoli c76501b8a3 'changed' key is not defined when task fails
fix KeyError introduced by fix of #6591.
2014-03-24 19:31:52 +01:00
Michael DeHaan d0cbb51170 Merge pull request #6615 from 8191/devel
Addresses #6591 Hide diff for lineinfile if file did not change.
2014-03-21 10:46:29 -04:00
Manuel Faux b8158f5f6a Addresses #6591 Hide diff for lineinfile if file did not change. 2014-03-21 08:40:38 +01:00
James Tanner ea5186ca63 Fixes #6590 add set_remote_user parameter to synchronize
This allows usage of custom ssh configs for remote hosts where
the inventory user does not match the configured user.
2014-03-20 13:56:07 -04:00
Michael DeHaan 94e3350b38 Catch a unquoted line error. Fixes #6532 2014-03-17 17:15:42 -04:00
James Tanner ebb6b8442b Catch unicode unescape failures in copy action plugin 2014-03-17 12:14:29 -04:00
Michael DeHaan 3d44f7cd51 Merge pull request #6217 from ashokrajar/patch-1
pause plugin doesn't flush raw_input prompt
2014-03-16 12:32:58 -05:00
Cristian Ciupitu 0749112286 Micro-optimization: replace s.find(x)!=-1 with x in s
timeit shows a speedup of ~3x on Python 2.7.5 x86_64.
It also makes the code a bit shorter.
2014-03-16 13:10:28 -04:00
James Cammarata 9f2999df79 Un-escape newlines in delimiters for assemble module 2014-03-06 09:44:56 -06:00
James Tanner 4e8ed92130 Fixes #6077 decode escaped newline characters in content for the copy module 2014-03-05 18:49:54 -05:00