1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00
Commit graph

4170 commits

Author SHA1 Message Date
Brian Coca
42b7321d4b Merge pull request #10587 from bcoca/fix_unrelated_lookup_fail
dont break everything when one of the vars in inject does not template
2015-04-02 15:49:18 -04:00
Toshio Kuratomi
5808b68d35 Update module pointers 2015-04-02 12:41:30 -07:00
Brian Coca
06c837cd87 Merge pull request #7487 from nirvinehh/devel
Clean non-printable chars from stdout instead of dropping the whole thin...
2015-04-01 21:36:03 -04:00
Brian Coca
4dd233b0dd Merge pull request #10237 from emonty/remove-auth-token
Remove auth token and port openstack module_utils changes to v2 tree
2015-04-01 12:20:59 -04:00
Brian Coca
1fa3dbb7d2 capture IOErrors on backup_local (happens on non posix filesystems)
fixes #10591
2015-04-01 12:12:34 -04:00
Brian Coca
f6714ac051 Merge pull request #10507 from renard/fix-patch-action-plugin
Fix patch action plugin
2015-04-01 09:57:34 -04:00
Monty Taylor
87c99b4675 Align verify parameter with validate_certs
The rest of ansible uses validate_certs, so make that the main
documented parameter. However, leave verify as an alias since that's the
passthrough value to the underlying libraries.
2015-04-01 07:54:02 -04:00
Brian Coca
0d1e2e74a1 converted error on play var initialization into warning with more information 2015-03-31 23:07:03 -04:00
Brian Coca
17e086fe8c dont break everything when one of the vars in inject does not template correctly, wait till its used 2015-03-31 21:36:18 -04:00
Monty Taylor
90ca386555 Add api timeout now that shade spports it everywhere 2015-03-31 20:29:06 -04:00
Brian Coca
f337707ef1 updated ref to pickup latest docfixes 2015-03-31 09:43:09 -04:00
Brian Coca
4919c225e6 updated ref so docs can build 2015-03-31 09:22:19 -04:00
Brian Coca
f812582d9c updated submodule refs 2015-03-31 08:47:30 -04:00
Toshio Kuratomi
68880a797d Update core to fix cloudformation problem 2015-03-30 19:15:41 -07:00
Brian Coca
299314c6b6 Merge pull request #10545 from resmo/feature/cloudstack-utils
cloudstack: common code used in cloudstack modules
2015-03-30 22:03:45 -04:00
Brian Coca
2a8a302e7e fixed corner case when counting backwards, added test cases for count=0 and backwards counts 2015-03-30 20:34:17 -04:00
Brian Coca
662b35cbce readded sudo/su vars to allow role/includes to work with passed sudo/su 2015-03-27 18:30:42 -04:00
Brian Coca
35a2ca8a5d made sequence more flexible, can handle descending and negative sequences and is skipped if start==end 2015-03-27 15:41:02 -04:00
Brian Coca
5ec1f3bd6e removed folding sudo/su to become logic from constants as it is already present downstream in playbook/play/tasks 2015-03-27 08:45:04 -04:00
Brian Coca
76e3a9c93a Merge pull request #9894 from 47lining/cloud_modules_sts_support_redux_ansible
Cloud Modules STS Support Redux
2015-03-27 08:20:43 -04:00
Toshio Kuratomi
b7936009c2 Correct typo 2015-03-26 12:09:36 -07:00
Toshio Kuratomi
0ec1b025a9 Update the module pointers 2015-03-26 11:59:53 -07:00
Toshio Kuratomi
5bf9ea6298 make sure the shebang we inject into the module is a str
Fixes #8564
2015-03-26 11:52:19 -07:00
Rene Moser
3e7d959c9d cloudstack: module utils are BSD licensed 2015-03-26 15:39:02 +01:00
Rene Moser
c066a60b7c cloudstack: fail_json() if library cs is not found 2015-03-26 15:32:58 +01:00
Rene Moser
1ba05dd3a2 cloudstack: add doc fragment 2015-03-26 14:18:23 +01:00
Rene Moser
bb6d983290 cloudstack: add utils for common functionality 2015-03-26 14:18:13 +01:00
Toshio Kuratomi
aaa25eb75c Make run_command() work when we get byte str with non-ascii characters (instead of unicode type like we were expecting)
Fix and test.

Fixes #10536
2015-03-25 12:24:49 -07:00
Toshio Kuratomi
c024057e97 Fix assert to work with unicode values 2015-03-25 12:24:49 -07:00
Brian Coca
19ba26e9a5 makes raw module have quiet ssh so as to avoid extra output when not requried 2015-03-24 14:48:50 -04:00
Brian Coca
ec8118ec41 now ansible ignores tempate errors on passwords
they could be caused by random character combinations, fixes #10468
2015-03-21 02:02:59 -04:00
Brian Coca
72586d0df5 updated to latest core/devel 2015-03-20 17:27:00 -04:00
Toshio Kuratomi
8d8c4c0615 Update modules for asg tag fix 2015-03-20 11:39:58 -07:00
Eri Bastos
d4eddabb2a Patch for bug #10485 - ansible_distribution fact populates as 'RedHat' on Oracle Linux systems 2015-03-20 14:40:44 -03:00
Sébastien Gross
6888f1ccd9 [patch] Use _make_tmp_path to prevent from copying full patch file path. 2015-03-20 17:13:50 +01:00
Sébastien Gross
8a5f162e29 [patch] fix "remote_src" behavior according patch module documentation.
Patch documentation says "remote_src" us False by default. That was not
the case in the action plugin.
2015-03-20 16:45:54 +01:00
Brian Coca
d4ebe77502 now use combine vars to preserve existing cached host vars 2015-03-20 11:34:18 -04:00
Brian Coca
a53cf9d6fa now correctly aplies add_host passed variables last to override existing vars. 2015-03-20 11:22:07 -04:00
Brian Coca
0c57bed728 now add_host loads hostvars 2015-03-20 10:14:53 -04:00
Toshio Kuratomi
6264eb4e02 Pull in ec2_asg fixes from core modules 2015-03-19 22:45:47 -07:00
Toshio Kuratomi
ac1c49302d Update core modules pointer 2015-03-19 12:50:46 -07:00
Brian Coca
456f83962d ignore PE methods that are not sudo for checksums until we get them working universally 2015-03-19 14:31:00 -04:00
Toshio Kuratomi
73f5a1fcdd Update the extras module pointer 2015-03-18 20:25:53 -07:00
Toshio Kuratomi
b8efd3f777 Update core module pointer 2015-03-18 19:55:13 -07:00
Toshio Kuratomi
9dd5f8c758 Update core module pointer 2015-03-18 18:30:10 -07:00
Brian Coca
fd2d7fe447 Merge pull request #10290 from bcoca/remove_bare_warning
removed bare variable detection as this confuses people
2015-03-18 20:43:56 -04:00
Brian Coca
ba4e9a4c82 added missing become method inventory override 2015-03-17 19:19:48 -04:00
Toshio Kuratomi
f9a66a7ff7 Update core module pointer 2015-03-17 11:03:15 -07:00
Toshio Kuratomi
e42848e0fe Better comment for why we have get_checksum call itself sometimes 2015-03-17 11:02:07 -07:00
Brian Coca
b11be68249 updated module ref 2015-03-16 19:40:37 -04:00
Brian Coca
bbdcba53da fixed bug on using su on play level not setting become method correctly 2015-03-16 19:37:03 -04:00
Brian Coca
a47c132695 slight changes to allow for checksum and other commands to work correctly with quoting 2015-03-16 19:09:03 -04:00
Toshio Kuratomi
37ab61c542 Update core pointer to make use of DOCKER_TLS_VERIFY env var:
https://github.com/ansible/ansible-modules-core/issues/946
2015-03-16 11:46:44 -07:00
Toshio Kuratomi
1bf0e60646 Update core module pointer 2015-03-16 11:34:55 -07:00
Brian Coca
b783ea94bb fixed raw return check for privilege escalation 2015-03-16 14:00:07 -04:00
Brian Coca
5eae435357 removed Darwin get_uptime_facts as it seems to crash on OS X, will waiy for a
patch tested by someone that has access to the platform
2015-03-16 13:41:36 -04:00
Chris Blumentritt
7813ffd719 Adding uptime_seconds fact for linux and darwin platforms
Adds ansible_uptime_seconds facts for linux and darwin platforms.  BSD
platforms may also work.
2015-03-13 15:52:16 -05:00
Toshio Kuratomi
8c3b5690e5 Merge pull request #10357 from htgoebel/devel
Fix detect of docker as virtualization_type.
2015-03-13 11:40:15 -07:00
James Cammarata
eb850bf81a Fix issue with unarchive disabling pipelining mode
Was using persist_files=True when specifying the create paramater,
which breaks pipelining. Switched to use delete_remote_tmp=False instead,
which is the proper way to preserve the remove tmp dir when running
other modules from the action plugin.
2015-03-12 10:22:06 -05:00
Brian Coca
a675b10b3b Merge pull request #10329 from bcoca/var_merge_combined
changed from hash_merge to combine vars which resets default to
2015-03-12 10:58:12 -04:00
Brian Coca
ac1493faae fixed missed conversion of su to become 2015-03-12 10:01:31 -04:00
Toshio Kuratomi
f5264414db Merge pull request #10426 from shirou/fix-hostvar-unicode-error
use to_unicode() in _jinja2_vars if type is str.
2015-03-11 20:39:50 -07:00
Shirou WAKAYAMA
d92e8edf6e set 'nonstring' arg to passthru. 2015-03-12 12:36:50 +09:00
Toshio Kuratomi
e413dba3a6 Update the module pointers 2015-03-11 19:10:38 -07:00
Brian Coca
f229b770b2 fixed missed su to become conversion 2015-03-11 19:23:02 -04:00
Brian Coca
587ab17f10 fixes password error detection for ssh connection plugin
removes sycnronize test that does not work with current sudo setup
Fixes #10434
2015-03-11 16:11:27 -04:00
Brian Coca
747c7aaffa removed uneeded reference to su_user 2015-03-11 12:33:05 -04:00
Brian Coca
de5eae2007 fixed traceback when x_user implicitly sets the become method
Fixes #10430

Also removed redundant resolution of sudo/su for backwards compatibility which
confused the conflict detection code.
2015-03-11 12:18:53 -04:00
Brian Coca
a5f533e25d fixed bad paren in connection plugin 2015-03-11 09:30:07 -04:00
Shirou WAKAYAMA
2d73892acf use to_unicode() in _jinja2_vars if type is str. 2015-03-11 14:50:27 +09:00
Brian Coca
5f6db0e164 preliminary privlege escalation unification + pbrun
- become constants inherit existing sudo/su ones
- become command line options, marked sudo/su as deprecated and moved sudo/su passwords to runas group
- changed method signatures as privlege escalation is collapsed to become
- added tests for su and become, diabled su for lack of support in local.py
- updated playbook,play and task objects to become
- added become to runner
- added whoami test for become/sudo/su
- added home override dir for plugins
- removed useless method from ask pass
- forced become pass to always be string also uses to_bytes
- fixed fakerunner for tests
- corrected reference in synchronize action plugin
- added pfexec (needs testing)
- removed unused sudo/su in runner init
- removed deprecated info
- updated pe tests to allow to run under sudo and not need root
- normalized become options into a funciton to avoid duplication and inconsistencies
- pushed suppored list to connection classs property
- updated all connection plugins to latest 'become' pe

- includes fixes from feedback (including typos)
- added draft docs
- stub of become_exe, leaving for future v2 fixes
2015-03-10 18:42:36 -04:00
Brian Coca
17c710e713 Merge pull request #10420 from bmanojlovic/devel
add missing AIX network facts discovery
2015-03-10 15:59:34 -04:00
Boris Manojlovic
a59784a581 don't use full path to command instead use module.get_bin_path 2015-03-10 19:44:39 +01:00
Matt Martz
4990814901 Prevent an empty error message 2015-03-10 11:30:28 -05:00
Boris Manojlovic
0f4cf8cb43 add missing AIX network facts discovery 2015-03-10 15:19:29 +01:00
pyroscope
d0197195ed Handle /etc/os-release files with 'Raspbian' in them 2015-03-10 08:41:21 +01:00
Brian Coca
d244390064 correclty added inventory this time 2015-03-09 12:15:41 -04:00
Brian Coca
642d9d6b56 readded inventory vars to runner's vars 2015-03-09 12:12:37 -04:00
Brian Coca
5453e2cbb8 removed redundant inventory call, moved grousp to proper priority 2015-03-09 10:27:59 -04:00
Chris Church
919db1025c Merge pull request #9601 from cchurch/set_delegate_before_connect
Set delegate on connection plugin before calling connect()
2015-03-08 21:12:39 -04:00
riedel
29cca0191b Adding oVirt recognition for oVirt guests. oVirt uses KVM. 2015-03-07 10:17:41 -05:00
Toshio Kuratomi
3e311db128 Update core and extras module pointers 2015-03-06 21:02:40 -08:00
Monty Taylor
8758ba08bd Update common OpenStack requests-related parameters
Also, update docs related to earlier changes in this stack.
2015-03-06 18:20:45 -05:00
Monty Taylor
8027a8a0b5 Change to auth_type to match python-openstackclient 2015-03-06 18:11:12 -05:00
Toshio Kuratomi
d706fd1eda Merge pull request #10388 from willthames/no_log_skipped
Don't log item data for skipped tasks under no_log
2015-03-05 16:34:38 -08:00
Brian Coca
c3d34a5386 Merge pull request #8936 from srvg/inventoryscript_onlychildren
Allow InventoryScript JSON with childgroups only
2015-03-05 17:11:04 -05:00
Brian Coca
761540e9fd Merge pull request #10392 from sgordon46/devel
facts.py throws exception when run on RHEV hypervisor #10383
2015-03-05 12:09:49 -05:00
Brian Coca
aed493158c Merge pull request #9428 from landryb/openbsd_add_mount_facts
parse /etc/fstab on OpenBSD to get mount facts
2015-03-05 12:07:27 -05:00
Stephen Gordon
b44bf0379b facts.py throws exception when run on RHEV hypervisor #10383 2015-03-05 10:28:26 -06:00
Will Thames
13a591eac0 Don't log item data for skipped tasks under no_log
Tasks with `no_log` set should not log data.
Remove log of item data for skipped tasks in loops

Fix for #10387
2015-03-05 14:51:05 +10:00
Toshio Kuratomi
241b905e85 Update core module pointer to fix mysql bug 2015-03-04 18:59:12 -08:00
Toshio Kuratomi
983b617fb7 Update the modules 2015-03-04 18:56:50 -08:00
Toshio Kuratomi
fbc525cfb6 Use to_bytes instead of .encode(). Fixes the fact that errors is a positional argument, not a kw arg in .encode() 2015-03-04 11:07:00 -08:00
Toshio Kuratomi
ffb281d96c Merge pull request #9600 from msabramo/make_AnsibleError_a_plain_ol_exception
Make AnsibleError a plain ol' exception
2015-03-03 09:56:09 -08:00
Brian Coca
d43f542c1e Merge pull request #10373 from keithbentrup/patch-1
Incorrect keyword argument 'error'
2015-03-03 07:53:57 -05:00
Toshio Kuratomi
a8c02b7049 Rework the shell quoting of remote checksumming
Instead of getting rid of pipes.quote, use pipes.quote and get rid of
the manually entered toplevel quotes.  This should properly escape
backslashes, quotes, and other characters.

Also fix the new checksumming python "one-liner" for csh.
ansible_shell_type needs to be set to csh.

Fixes #10363
Fixes #10353
2015-03-02 15:42:18 -08:00
Toshio Kuratomi
c14a436df9 Update core and extras module pointers 2015-03-02 15:40:11 -08:00
Keith
788258917f Incorrect keyword argument 'error'
Incorrect keyword argument 'error'. It should be 'errors'.
2015-03-02 17:52:07 -05:00
James Cammarata
0314180dbe Updating core modules submodule pointer 2015-03-02 09:46:26 -06:00
Hartmut Goebel
8758ae201d Fix detect of docker as virtualization_type.
Not only match`/docker/`, but also `docker-` followed by a hex-id.

Example (shortened):
```
$ cat /proc/1/cgroup
8:blkio:/system.slice/docker-de73f4d207861cf8757b69213ee67bb234b897a18bea7385964b6ed2d515da94.scope
7:net_cls:/
```
2015-02-28 14:13:58 +01:00
Toshio Kuratomi
a5ac9aafad Update modules for docs fix 2015-02-27 08:50:09 -08:00
Brian Coca
49fce3587b Merge pull request #10311 from jpmens/lookup-module-dig1
New lookup-plugin: `dig' for performing DNS lookups
2015-02-27 09:33:26 -05:00
Jan-Piet Mens
a3618f619e New lookup-plugin: `dig' for performing DNS lookups
add support for argument qtype=XXX
remove spurious print
add dict returns
typo
Add dict returns for all major DNS types
Finish adding more types. For now. Until somebody complains.
I forgot to add NAPTR; here it is.
2015-02-27 09:16:50 +01:00
Toshio Kuratomi
38a5110250 Update core modules for docs fix 2015-02-26 22:53:27 -08:00
Toshio Kuratomi
084fbbdea9 Reverse the conditional so there's one less return from this function 2015-02-26 22:50:11 -08:00
Brian Coca
346689f9f2 Merge pull request #9293 from cchurch/module_suffixes
Simpler fix for module suffixes than c02e8d8c8.
2015-02-26 23:33:51 -05:00
Brian Coca
5a64b2e269 Merge pull request #10305 from bcoca/cartesian
Cartesian
2015-02-26 23:25:33 -05:00
Brian Coca
942ff8d0b9 Merge pull request #10035 from phenomenes/fix_9911
Adds seconds to backup timestamp
2015-02-26 22:44:23 -05:00
Brian Coca
5d729edd2f Merge pull request #9458 from sthen/openbsd_arch
set CPU architecture correctly for OpenBSD (powerpc not macppc, etc.)
2015-02-26 22:41:21 -05:00
Toshio Kuratomi
0f4b72cdfa Refactor loop to only calculate the full_path once 2015-02-26 16:01:42 -08:00
Toshio Kuratomi
68c99a12b3 Merge pull request #10346 from lekum/find_plugin_bugfix
Bug fix: Search only for files as candidates
2015-02-26 15:38:45 -08:00
Toshio Kuratomi
89159951dc Fix name of a task containing a template causing traceback
Workaround for #10321 Need to fix better in v2
2015-02-26 14:05:33 -08:00
Toshio Kuratomi
825dd25d43 Update module pointers 2015-02-26 13:52:10 -08:00
Toshio Kuratomi
8a5067d628 Adapt sanitize_output to log messages instead of assuming properly formatted key-value pairs
Fixes #10332
2015-02-26 12:31:11 -08:00
Alejandro Guirao
b8cf131375 Bug fix: Search only for files as candidates 2015-02-26 19:13:07 +01:00
Monty Taylor
0b8773fc99 Remove state from central argument list
There is an old PR that shows a great use case for having a different
set of states for the server module. Before the other modules start
being in real use, pull this out so that we don't get ourselves into a
pickle.
2015-02-26 11:35:29 -05:00
Brian Coca
2d74bd4891 pulled in add_hosts docfix 2015-02-26 10:21:15 -05:00
Brian Coca
dfc4fc5374 updated submodule refs 2015-02-26 10:04:11 -05:00
Toshio Kuratomi
ac40ffa157 If remote_checksum fails because the dest is a directory, try a file within the dest.
Fixes #10300
2015-02-25 11:26:43 -08:00
Toshio Kuratomi
d5af0ba346 Comment explaining return codes from checksum() 2015-02-25 11:26:43 -08:00
Brian Coca
c81d981164 Merge pull request #10183 from bcoca/tag_control
adds complex tag management
2015-02-25 10:36:11 -05:00
Brian Coca
a1e2ae083d Merge pull request #10320 from bcoca/ssh_fix_notokens
skips certain ssh errors and attempts to continue
2015-02-25 10:34:04 -05:00
Brian Coca
9ad8475be9 Merge pull request #9605 from msabramo/more_ssh_error_info
Display more info when SSH errors occur
2015-02-25 09:27:49 -05:00
Brian Coca
4fa51652b4 fixed typoe in combined_Vars 2015-02-24 05:26:41 -05:00
Brian Coca
ce764063f1 corrected merge vs combined in all pertinent sections 2015-02-24 05:14:22 -05:00
Brian Coca
e59b364641 changed from hash_merge to combine vars which resets default to
overwrite and not merge hashing
2015-02-24 05:05:27 -05:00
Matt Stephenson
a2ea785d69 Add function to ipaddr for getting the nth host within a network 2015-02-23 13:42:03 -08:00
Matt Stephenson
ce17f5e1ec Fix indentation 2015-02-23 12:51:19 -08:00
Brian Coca
65e68cdff9 Merge pull request #10316 from whereismyjetpack/winrm_https
plaintext https transport connecting over http
2015-02-23 11:00:33 -05:00
Toshio Kuratomi
a6fbd83660 * Transform vars_prompt result to unicode type before returning (Fixes #10319)
* Rename prompt method as do_prompt to avoid potential bug when logging via a callback plugin
2015-02-23 07:59:20 -08:00
Toshio Kuratomi
920b71984e lists => frozenset as we're only using them in membership checks 2015-02-23 07:09:33 -08:00
Brian Coca
b9aa8f07be skips certain ssh errors and attempts to continue
should fix #10225
2015-02-23 05:17:41 -05:00
Dann Bohn
5da5fa15c6 rm duplicate 2015-02-22 02:29:10 -05:00
Dann Bohn
b9bfb22a9d fix https transport bug 2015-02-21 17:43:59 -05:00
Alvaro Lopez Ortega
2e929cf0ce Fixes bug #10281 - Trailing zeros were truncated from strings 2015-02-21 19:54:38 +01:00
Alvaro Lopez Ortega
a14248ffe1 Fixes bug #10281 - Trailing zeros were truncated from strings 2015-02-21 16:40:50 +01:00
Brian Coca
6b64fe8bdd Merge pull request #9936 from sysadmin75/9415_hostname_as_dir
Fixes #9415 - fetch: should use hostname instead of ip for directory name
2015-02-20 11:14:48 -05:00
Brian Coca
acbd096cf3 Merge pull request #10298 from bcoca/lookup_wantlist
Allow requesting a list to lookup plugins instead of , delimited string
2015-02-20 10:16:57 -05:00
Brian Coca
5d946ec4f2 adds cartesian product lookup 2015-02-20 09:04:00 -05:00
Brian Coca
1d90ff8b34 Merge pull request #10304 from dago/ldom
Add LDom support
2015-02-20 08:09:58 -05:00
Dagobert Michelsen
c1dba60961 Use try block for field splitting 2015-02-20 13:57:02 +01:00
Dagobert Michelsen
90e760ba84 Add LDom support 2015-02-20 10:11:06 +01:00
Brian Coca
57674fa047 Allow requesting a list to lookup plugins instead of , delimited string 2015-02-19 18:29:29 -05:00
Brian Coca
e842f8fab9 Merge pull request #10295 from bcoca/show_return_val_docs
ansible-doc now shows return value docs
2015-02-19 18:00:06 -05:00
Brian Coca
c587bf1488 fixed absolute_import to be on top as it requries 2015-02-19 16:45:34 -05:00
Brian Coca
c2023f6f59 Merge pull request #10285 from bcoca/math_filter_rearrange
rearranged math filters
2015-02-19 16:04:26 -05:00
Brian Coca
1e818f9c50 ansible-doc now shows return value docs 2015-02-19 13:18:05 -05:00
Brian Coca
8be8a7e2f5 Merge pull request #10277 from dago/solaris
Add Solaris zone support for inventory and connection

NOTE: the connection plugin will need some work for v2 (after 1.9 gets released)
2015-02-19 13:13:31 -05:00
Brian Coca
414737557e Merge pull request #10284 from mihirvj/devel-10221
Pulls machine id in ansible facts
2015-02-19 12:56:45 -05:00
Brian Coca
e6ac2fa593 Merge pull request #10292 from dago/solaris-mounts
Add support for mounts in Solaris facts
2015-02-19 12:46:37 -05:00
Dagobert Michelsen
b82a8576f1 Add support for mounts in Solaris facts 2015-02-19 15:38:20 +01:00
Brian Coca
7044b5a8d1 removed bare variable detection as this confuses people and forced us to allow for bare expressions 2015-02-19 08:29:53 -05:00
Brian Coca
c92c4e7376 readded absolute_import 2015-02-19 07:39:45 -05:00
Brian Coca
8872bba21f rearranged math filters 2015-02-18 20:03:05 -05:00
Mihir Joshi
58a5f8dfaf Pulls machine id in ansible facts
- Fix #10221
2015-02-18 17:10:36 -05:00
Dagobert Michelsen
81f55ff8ff Adjust leftovers from chroot 2015-02-18 16:52:44 +01:00
jensdepuydt
730c2ba403 minor change to not search in non-existing paths 2015-02-18 12:07:35 +01:00
jensdepuydt
adc0e8be97 Merge branch 'optimize-plugin-loader-10165' of github.com:ansible/ansible into optimize-plugin-loader-10165 2015-02-18 12:04:54 +01:00
Toshio Kuratomi
68e86de26f Optimize the plugin loader.
We have been caching the paths to the plugins but before we would only
cache the specific plugin that we were looking for.  This meant that we
might search through all of the plugin directories before finding the
specific module we were interested in.  The next plugin we needed we
might again search through all the plugin directories before finding the
plugin we wanted.

This new code will cache all the potential plugins in each directory
searched.  For a play that only uses one plugin we'll only search
through directories until we encounter the directory that has the proper
plugin.  For a large playbook with many plugins used we'll search
through each directory at most once each.

This should alleviate #10165
2015-02-17 13:24:46 -08:00
Dan Rue
67eb9f301d Do not mark "skipped" when changed is false
When using the "creates" option with the script module, set changed
to False if the file already exists. This behavior is consistent with
other modules which use "creates", such as command and shell.
2015-02-17 15:14:21 -06:00
Dan Rue
787388ac30 Do not mark "skipped" when changed is false
When using the "creates" option with the unarchive module, set changed
to False if the file already exists. This behavior is consistent with
other modules which use "creates", such as command and shell.
2015-02-17 15:02:08 -06:00
Toshio Kuratomi
5738ee1cb3 Update core modules to fix new integration tests 2015-02-16 22:08:53 -08:00
Brian Coca
6f6c6fb32a Merge pull request #10259 from sivel/rax-boot-vol-v2
Add new rax_find_bootable_volume to assist with boot from volume
2015-02-16 18:04:16 -05:00
Toshio Kuratomi
8f9b761f3a Merge pull request #10128 from alxgu/fix_facts_for_sles
Fix wrong distribution facts on SLES/openSUSE
2015-02-16 13:24:12 -08:00
Stratos Moros
6caeded74e Fix umask calculation on file creation. Fixes #10257 2015-02-16 21:16:26 +02:00
Brian Coca
6a29251292 Merge pull request #10248 from hfinucane/gh-9888
Add `groups` back into inline templates
2015-02-16 13:56:20 -05:00
Brian Coca
e41d48104f valutpass fix in password reorog 2015-02-16 12:24:43 -05:00
Brian Coca
b2d5919d6d Merge pull request #10250 from cove/cyaml
improve yaml parsing performance by ~25% by using PyYAML's CParser loader
2015-02-16 12:11:58 -05:00
Brian Coca
a022aed43d Merge pull request #10229 from bcoca/patch_not_require_dest
patch action plugin does not require dest
2015-02-16 11:18:27 -05:00
Toshio Kuratomi
d0556885ff Update modules 2015-02-16 07:14:11 -08:00
Toshio Kuratomi
c9fb97cc86 Be careful not to set the permissions of the destination of a symlink.
It's up to the module using the set_fs_attributes*/set_mode* methods to
specify the filename of the destination of the symlink if that's really
the file that should be modified.

Half of the fix for:
https://github.com/ansible/ansible-modules-core/issues/778
2015-02-16 07:07:58 -08:00
Alexander Gubin
d291dae582 Exit loop after detecting os-release 2015-02-16 13:18:11 +01:00
Cove Schneider
825654a2fa parse yaml using cparser if present 2015-02-16 00:26:35 -08:00
Henry Finucane
2e4191c013 Add groups back into inline templates 2015-02-15 20:16:41 -08:00
Toshio Kuratomi
1e867b0b8e Fix the to_nice_yaml filter to always return unicode strings
Fixes #10243
2015-02-14 22:25:56 -08:00
Matt Martz
cfd05ceafc Add new rax_find_bootable_volume to assist with boot from volume 2015-02-13 15:25:42 -06:00
Monty Taylor
4e4bdaad8d Remove auth_token parameter
It turns out that this can actually already be handled by the existing
auth plugin framework and does not need its own parameter. Remove before
it sees usage and causes confusion.
2015-02-13 10:42:20 -05:00
Brian Coca
f6a6df2169 removed unused method 2015-02-13 08:27:35 -05:00
Brian Coca
65c08d1364 added tests
refactored task selection into method
list-tasks now uses common method of task selection
always is now skippable if specified in --skip-tags
2015-02-13 08:27:07 -05:00
Brian Coca
6fbbf9c118 simplified if conditions 2015-02-13 08:27:07 -05:00
Brian Coca
6579c5ddf5 fixed skipped tags 2015-02-13 08:27:07 -05:00
Brian Coca
95fa770ba0 adds complex tag management
Adds a special tag:
 - always: always runs no matter what --tags, --skip-tags say

Adds 4 special keywords for --tags/skip-tags
 - all: all tagged + untagged tasks
 - tagged: only tagged tasks
 - untagged: only untagged tasks
 - always: only run tasks tagged 'always'
2015-02-13 08:27:07 -05:00
Brian Coca
f61de115cd updated version added for pkg5* 2015-02-13 08:21:50 -05:00
Brian Coca
64690691d3 updated to pickup fixed cpanm 2015-02-13 08:10:26 -05:00
Brian Coca
932fd2eda2 fixed vault pass also 2015-02-12 19:03:50 -05:00
Brian Coca
0087816b13 fixed varname su_pass 2015-02-12 19:03:04 -05:00
Brian Coca
69b76a48b0 dest is not required as patchfile can have that info 2015-02-12 18:52:58 -05:00
Brian Coca
5f2d5abeea ensure proper strings/unicodestrings for passwords
updated to correct to_bytes function
removed old to_bytes/to_unicode and repointed clients to new location
fixed unicode test
2015-02-12 17:44:08 -05:00
Toshio Kuratomi
9d605171a7 Didn't port isbasestring/isunicodestring from kitchen so switch to isinstance 2015-02-12 13:55:27 -08:00
Toshio Kuratomi
740bd8fbde Update to fix logentries issues 2015-02-12 12:58:36 -08:00
Toshio Kuratomi
dd484e8211 Update modules 2015-02-12 12:16:31 -08:00
Brian Coca
62a6378c4a Merge pull request #8792 from bcoca/ternary_filter
ternary filter
2015-02-12 11:29:49 -05:00
Brian Coca
0912781357 Merge pull request #9421 from emonty/features/new-openstack
Add support for new OpenStack modules
2015-02-12 10:26:12 -05:00
Brian Coca
1b4f1e1756 Merge pull request #9555 from bcoca/low_cost_facts
allow fact objects to be instantiated w/o triggering all fact collection
2015-02-11 20:57:40 -05:00
Brian Coca
fd987f5395 Merge pull request #9063 from sivel/extra-vars-adhoc
Allow ansible (ad-hoc) to support --extra-vars
2015-02-11 20:46:37 -05:00
Matt Martz
68358e31fb Allow ansible (ad-hoc) to support --extra-vars also 2015-02-11 19:34:01 -06:00
Toshio Kuratomi
6fe8865885 Return empty string if unable to read from some files during fact gathering so as not to change the values we return 2015-02-11 14:53:53 -08:00
Brian Coca
13d788021f Merge pull request #4820 from mscherer/add_local_config
Add path for user defined plugin
2015-02-11 14:44:07 -05:00
Monty Taylor
9b17918bc9 Add doc fragment for new OpenStack modules 2015-02-11 14:04:59 -05:00
Monty Taylor
8c7267f9b9 Add support for new OpenStack modules
Incoming cloud config for OpenStack is complex due to plugins and
deployer choices. Rather than having the logic spread all over the
OpenStack modules, centralize it in the module_utils code.
2015-02-11 14:04:27 -05:00
Brian Coca
788889225d Merge pull request #10078 from sgargan/consul
Ansible support for Consul
2015-02-11 13:58:15 -05:00
Brian Coca
0b8101aec3 Merge pull request #10141 from dresden-weekly/fix_#10051
fixes #10051 as suggested by @aikomastboom
2015-02-11 13:57:04 -05:00
Brian Coca
c966eb5d80 Merge pull request #10015 from bcoca/nicer_json_errors
handle json load errors as ansible error instead of ugly stacktrace
2015-02-11 13:31:25 -05:00
Dagobert Michelsen
9cf8c3a901 Add support for Solaris zones 2015-02-11 16:48:04 +01:00
Nicolas Le Manchet
faa2449f55 Set proper permissions for ansible-vault view 2015-02-11 14:15:38 +01:00
Toshio Kuratomi
10df1b898c Fix template module broken when modifying symlinks
Needed to clear unwanted parameters from both args and complex args when
calling file module.

Fixes #10208
2015-02-11 00:10:37 -08:00
Kirk Strauser
ab33a0e666 Adds Kerberos authentication to winrm if available
If the `kerberos` module is available, winrm will attempt to establish a
Kerberized connection to a Windows server. This allows use of Windows
domain accounts, which are quite often the only kinds of accounts
enabled on enterprise networks.

This also pulls the `transport_schemes` variable up into the
`winrm.Connection` class. This lets tests or future modifications alter
the list of available schemas without reaching into `Connection.__init__`.
2015-02-10 07:39:07 -08:00
Brian Coca
416a4c3342 Merge pull request #10199 from bcoca/su_ssh_fix
fixes su/ssh with null prompt
2015-02-10 09:49:35 -05:00
Brian Coca
f7ad6ad4de fixed issue with prompt == none and su + ask_pass in ssh plugin 2015-02-10 08:47:11 -05:00
Henk Wiedig
0a902a5afd make su promt AIX compatible
$ su suuser date
suusers's Password:
2015-02-10 05:18:37 -05:00
Brian Coca
75d3c6b104 Merge pull request #10185 from bcoca/valut_editor_missing_err
better missing editor message
2015-02-09 18:16:57 -05:00
Brian Coca
2f2fe734df Merge pull request #10192 from bcoca/patch_action_plugin
support for patch module to have master as src
2015-02-09 18:08:34 -05:00
Toshio Kuratomi
402a6d0533 Explicitly close files opened by facts
Fixes #10157
2015-02-09 14:30:06 -08:00
Brian Coca
476b0f6d99 support for patch module to have master as src 2015-02-09 16:34:49 -05:00
Toshio Kuratomi
425dee1afa Close some file handles explicitly in facts.py
Helps control open file descriptor count with pypy (which is used with
one coreos + ansible example).  Part of a fix for
https://github.com/ansible/ansible/issues/10157
2015-02-09 13:06:33 -08:00
Toshio Kuratomi
9db17afc85 Update modules 2015-02-09 11:00:57 -08:00
Toshio Kuratomi
4902c06304 Obfuscate passwords in more places where it is displayed 2015-02-09 10:13:13 -08:00
Brian Coca
8b7dc6bbfb better missing editor message
fixes #10182
2015-02-08 23:26:56 -05:00
Toshio Kuratomi
3f97fc2ba6 Merge pull request #10162 from jonhadfield/fix_2.4_hashing
correct typo that breaks hashing on python 2.4.
2015-02-04 09:44:40 -08:00
Brian Coca
07dfbaedc3 Merge pull request #9602 from cchurch/powershell_splatting
Handle PowerShell parameters passed via splatting
2015-02-04 10:25:03 -05:00
Jon Hadfield
6874f5056d correct typo that breaks hashing on python 2.4. 2015-02-04 13:46:49 +00:00
Alexander Gubin
1968f99691 Wrong OS_FAMILY declaration for openSUSE 2015-02-04 09:16:32 +01:00
Toshio Kuratomi
019f74dced Update modules 2015-02-03 09:02:46 -08:00
Brian Coca
1b8d0b68a8 Merge pull request #10158 from bcoca/hosts_better_error
more resilient errors for bad host declarations in play
2015-02-03 10:33:47 -05:00
Brian Coca
cbbe2f4e26 more resilient errors for bad host declarations in play
should fix #10148
2015-02-03 10:26:48 -05:00
Brian Coca
7ea2aff272 Merge pull request #9772 from jszwedko/allow-template-for-retries
Allow retries to be templatable
2015-02-03 07:08:22 -05:00
Toshio Kuratomi
788e47b693 Correct filter specification 2015-02-02 19:21:26 -08:00
Toshio Kuratomi
8fd7f4b121 Wrap some filters so they return unicode.
The rules are -- if the filter returns str type and the str may contain
non-ascii characters then wrap it to convert to unicode type.  Not
needed if the function already returns unicode type or only returns
ascii characters
2015-02-02 19:11:12 -08:00
Toshio Kuratomi
a04138a887 Add v2's unicode.py to utils so we can use unicode_wrap in the filter_plugins 2015-02-02 19:09:08 -08:00
Toshio Kuratomi
6d788629a2 Be explicit about unicode str transformation
Fixes #10126
2015-02-02 13:37:31 -08:00
Toshio Kuratomi
97438f0039 Update the modules 2015-02-02 10:25:59 -08:00
Toshio Kuratomi
0e5f86cce4 Import hash functions for filters from the new location so the plugins will work on v1 and v2 2015-02-02 10:25:09 -08:00
Toshio Kuratomi
1011959d88 Move the hashing util functions to their own file to mirror v2 2015-02-02 10:25:09 -08:00
Toshio Kuratomi
b3af2f9bee Better error message 2015-02-02 08:52:19 -08:00
Toshio Kuratomi
f6e8ddfd5f Use pass instead of bare None value 2015-02-02 08:52:19 -08:00
Toshio Kuratomi
624a8dd1d9 Replace large if-elif-else blocks with a dict-dispatcher 2015-02-02 08:52:19 -08:00
Toshio Kuratomi
616fda5767 First try at only failing if the filter is actually used. 2015-02-02 08:52:19 -08:00
Maciej Delmanowski
7e46554160 Add ipaddr() filter plugin 2015-02-02 08:52:19 -08:00
Brian Coca
17666a1939 changed default for new retry path to be teh same as current
also added commented out entries in ansible.cfg to show other options
2015-01-30 15:18:58 -05:00
Brian Coca
540d13cf52 Merge pull request #9404 from mmoya/configure-retry-files
Configure retry file usage and location
2015-01-30 15:14:27 -05:00
Andreas Reischuck
6609f3ac03 fix suggested by @aikomastboom 2015-01-30 21:04:52 +01:00
Toshio Kuratomi
ca35d138f1 Update modules 2015-01-30 07:46:36 -08:00
Toshio Kuratomi
f355c11a3f Merge pull request #10129 from RadishTheHut/memfacts-fix
Fix for memory fact gathering
2015-01-30 07:44:58 -08:00
Brian Coca
7ab95e10f0 updated to latest core devel 2015-01-30 08:29:58 -05:00
Patrick McConnell
04b2c698ba Updated memory facts fix using dict.get() to avoid KeyError 2015-01-30 05:59:34 +01:00
Toshio Kuratomi
747cc26ae1 Update modules 2015-01-29 18:31:15 -08:00
Toshio Kuratomi
f20967078e Fixes to @RadishTheHut's memory facts as discussed in
https://github.com/ansible/ansible/pull/10129#issuecomment-72077500

* Switch default value from 0 to None.
* Prefill keys with default value so that determining calculated values
  is easier
2015-01-29 12:09:19 -08:00
Marc Abramowitz
372a29744b Make AnsibleError a plain ol' exception
Python's Exception constructor already takes a `message` as a parameter,
which you can then get at by doing str(e) (e.message was deprecated).

The reason I bothered to make this change was because I was debugging
with pdb and I noticed that AnsibleErrors don't give useful information
in pdb (probably because they don't have a __repr__ method that prints
the `msg` attribute).

    (Pdb) c
    > /Users/marca/dev/git-repos/ansible/lib/ansible/runner/__init__.py(599)_executor()
    -> msg = str(ae)
    (Pdb) ae
    AnsibleError()
2015-01-29 10:36:06 -08:00
Brian Coca
c73254543a made env var also consistent 2015-01-29 13:32:00 -05:00
Brian Coca
4fd760467b made inventory consistent in config file, deprecated old config hostfile 2015-01-29 13:28:33 -05:00
Brian Coca
751701c6f2 Merge pull request #9672 from quinot/topic/lineno-in-inventory-err
Report location (filename and line number) for inventory syntax errors
2015-01-29 12:36:30 -05:00
Brian Coca
e4a7b973fd Merge pull request #9128 from msabramo/expose_more_user_facts
Expose more facts about user on host system
2015-01-29 09:55:30 -05:00
Patrick McConnell
0c3a273805 Fix for memory fact gathering
I have a host which started to fail while gathering facts after the addition
of expanded memory facts in PR #9839:

Traceback (most recent call last):
  File "/home/ansible/.ansible/tmp/ansible-tmp-1422536976.05-133253824703289/setup", line 4278, in <module>
    main()
  File "/home/ansible/.ansible/tmp/ansible-tmp-1422536976.05-133253824703289/setup", line 137, in main
    data = run_setup(module)
  File "/home/ansible/.ansible/tmp/ansible-tmp-1422536976.05-133253824703289/setup", line 81, in run_setup
    facts = ansible_facts(module)
  File "/home/ansible/.ansible/tmp/ansible-tmp-1422536976.05-133253824703289/setup", line 4217, in ansible_facts
    facts.update(Hardware().populate())
  File "/home/ansible/.ansible/tmp/ansible-tmp-1422536976.05-133253824703289/setup", line 2339, in populate
    self.get_memory_facts()
  File "/home/ansible/.ansible/tmp/ansible-tmp-1422536976.05-133253824703289/setup", line 2375, in get_memory_facts
    'cached': memstats['swapcached']
KeyError: 'swapcached'

My problem host doesn't have SwapCached in /proc/meminfo. It may be better to
set defaults for these keys, since the values provided by /proc/meminfo can
change from version to version.
2015-01-29 15:00:01 +01:00
Alexander Gubin
5dec45e24a Fix wrong distribution facts on SLES/openSUSE 2015-01-29 14:54:53 +01:00
Toshio Kuratomi
556d4f0025 Update core modules 2015-01-28 16:31:08 -08:00
Toshio Kuratomi
44fe38030f Update core modules for subversion fixes 2015-01-28 16:17:30 -08:00
Toshio Kuratomi
3d5523fbb7 Fix for unicode filenames for template module
Fixes #10110
2015-01-28 14:24:57 -08:00
Toshio Kuratomi
0aac6360e4 Update core modules 2015-01-28 10:38:36 -08:00
Brian Coca
990d08b63f Merge pull request #10113 from bcoca/url_lookup
Url lookup
2015-01-28 09:54:40 -05:00
Brian Coca
11005e7b28 Merge pull request #9839 from nousdefions/memfacts
Memfacts
2015-01-28 09:39:24 -05:00
Brian Coca
3d6b6edea9 added url lookup plugin 2015-01-27 17:26:18 -05:00
Toshio Kuratomi
35321ec642 ansible.utils to_unicode/to_bytes isn't robust in the face of
non-strings.  Do some value checking in the calling code
2015-01-27 14:18:06 -08:00
Toshio Kuratomi
975b547aaa Update core modules 2015-01-27 09:47:20 -08:00
Toshio Kuratomi
a63e4c595f Another place that needs to be json_dict_bytes_to_unicode 2015-01-26 22:04:51 -08:00
Toshio Kuratomi
0f6b87d33e Revert "Fix import statements" -- those impotrt statements were right
before... something else is fishy

This reverts commit 8ab536fbf2.
2015-01-26 22:01:52 -08:00
Toshio Kuratomi
8ab536fbf2 Fix import statements 2015-01-26 21:49:09 -08:00
Toshio Kuratomi
d3666f3265 Make py2.4 remote checksum large-file-enabled as well 2015-01-26 21:44:42 -08:00
Toshio Kuratomi
6f5d18a20e Merge pull request #10087 from axos88/devel
fix checksum calculation for large files
2015-01-26 21:40:09 -08:00
Toshio Kuratomi
335cf2f05f Update module repos 2015-01-26 20:39:53 -08:00
Toshio Kuratomi
915d232d5f jinja2 cannot handle byte strs with non-ascii. So we need to transform potential byte str into unicode type. This fix is for dynamic inventory.
Fixes #10007
2015-01-26 20:39:09 -08:00
Brian Coca
9d190c8d8d Revert "Support variable values with dashes" 2015-01-26 12:54:50 -05:00
Brian Coca
13bbf9bfbb Merge pull request #9834 from nathancahill/fix-variables-with-dashes
Support variable values with dashes
2015-01-26 12:51:56 -05:00
Akos Vandra
03fa421f3f do not use with, it is not supported all the way down to 2.4 2015-01-25 18:42:59 +01:00
Akos Vandra
e8144b3b90 fixes #10086 2015-01-25 14:51:01 +01:00
Steve Gargan
c02f114967 Initial commit of Ansible support for the Consul clustering framework (http://consul.io).
Submission includes support for
 - creating and registering services and checks
 - reading, writing and lookup for values in consul's kv store
 - creating and manipulating sessions for distributed locking on values in the kv
 - creating and manipulating ACLs for restricting access to the kv store
 - inventory support that reads the Consul catalog and group nodes according to
     - datacenters
     - exposed services
     - service availability
     - arbitrary groupings from the kv store

This submission makes extensive use of the python-consul library and this is required
as a dependency and can be installed from pip.

The tests were written to target a vagrant cluster which can be setup by following the
instructions here http://github.com/sgargan/consul-vagrant
2015-01-24 01:09:03 +00:00
Toshio Kuratomi
53a3644ecd Update the modules 2015-01-22 23:17:58 -08:00
Toshio Kuratomi
364f772cc5 Fix quoting of shell parameters used in remote_checksum and add integration test to detect the error
Fixes #682
2015-01-22 12:33:06 -08:00
Brian Coca
54c25a101b Merge pull request #10029 from gaqzi/devel
Add filter to turn a string into a UUID
2015-01-22 14:51:40 -05:00
Toshio Kuratomi
f2b1a289ed Update modules to pull in fixes 2015-01-22 10:27:50 -08:00
Toshio Kuratomi
cce87acfed Fix integration test for unarchive to test zipfiles 2015-01-21 16:17:49 -08:00
Brian Coca
0e969aee06 updated submodules to latest devel 2015-01-21 19:09:22 -05:00
Björn Andersson
65e4f2b2bc Add filter to turn a string into a UUID
This filter was made because I needed to create idempotent UUIDs when
installing the agent for Go (http://go.cd), which uses UUIds to
distinguish the agents from each other.

It uses a newly created Ansible namespace to distinguish UUIDs created
by Ansible from any other source. The new namespace is a random one
created by uuidgen on OSX.
2015-01-21 08:07:17 +08:00
Brian Coca
82abe63eb2 Merge pull request #10055 from digi691/devel
Add the uuid of the device in ansible_mounts variable
2015-01-20 15:39:06 -05:00
Toshio Kuratomi
e6b5cc9ccb Merge pull request #9887 from lmacken/devel
Use send instead of sendv on the systemd.journal (fixes #9886)
2015-01-20 12:19:42 -08:00
cdigiovanni
99bcbe746f Add the uuid of the device in ansible_mounts variable 2015-01-20 10:58:14 -06:00
Brian Coca
2ef5d6be1e Merge pull request #9702 from bcoca/better_errors_on_delegate
better exception handling with delegated hosts
2015-01-19 15:25:01 -05:00
Brian Coca
23783a5228 Merge pull request #10014 from bcoca/inventory_script_errorhandle
ansible now captures returncode errors on inventory scripts
2015-01-19 15:17:56 -05:00
Brian Coca
2a9d5054bf Merge pull request #9995 from bcoca/hash_filters
Hash filters
2015-01-19 15:17:39 -05:00
Toshio Kuratomi
46e486ba41 Update modules to fix docs build and unittests 2015-01-19 09:43:30 -08:00
Toshio Kuratomi
01be9f4399 Update modules to latest 2015-01-19 09:07:49 -08:00
Brian Coca
78e1a7ed93 Revert "Fix: Add support for SSL protocol version configuration option" 2015-01-19 08:36:17 -05:00
Jimena Cabrera-Notari
1e865368ac Adds seconds to backup timestamp 2015-01-18 10:56:40 +00:00
Brian Coca
9ccabbb95e Merge pull request #9808 from swimlappy/sslconfig
Fix: Add support for SSL protocol version configuration option
2015-01-16 10:25:48 -05:00
Toshio Kuratomi
be4dbe76b9 Merge pull request #9997 from shawnsi/stdout_lines
Add stdout_lines to results when using with_items
2015-01-15 11:24:58 -08:00
Brian Coca
6b3d0f4788 now captures returncode errors on inventory scripts 2015-01-15 13:38:25 -05:00
Brian Coca
c09d27bca1 handle json load errors as ansible error instead of ugly stacktrace 2015-01-15 12:03:13 -05:00
Toshio Kuratomi
1b8faa68d9 Update extras to pick up doc build fix 2015-01-15 07:26:24 -08:00
Toshio Kuratomi
6326daa34e Update modules for unarchive handling user,group,mode and add integration test for the same 2015-01-14 19:23:12 -08:00
Shawn Siefkas
682b987567 Add stdout_lines to results when using with_items 2015-01-13 13:34:25 -06:00
Brian Coca
35247fabb8 added hash and password_hash functions
documented new hashing filters and preexisting hashing filters
removed extra sha1 example in others, clarified some of the hashing examples
2015-01-13 14:05:57 -05:00
Toshio Kuratomi
f1fdddb640 Do not send stat all the parameters that unarchive received
Fixes #546
2015-01-13 09:42:37 -08:00
Toshio Kuratomi
edc27c5a5b Fix to_nice_json on python2.6 2015-01-12 10:45:18 -08:00
Toshio Kuratomi
f2d37fba30 Update modules 2015-01-12 08:06:48 -08:00
Brian Coca
bd62530700 Merge pull request #9947 from maxamillion/issue-9759-fix-processor-facts
don't double the count of i for LinuxHardware cpuinfo keys on 'vendor_id' and 'model name' keys
2015-01-11 16:42:04 -05:00
Adam Miller
06b70e4f9c When checking for Xen for LinuxHardware processor facts, don't check sysfs if already found in /proc/ 2015-01-08 11:29:11 -06:00
Nate Coraor
60e815c844 Set ansible_distribution_version differently for Solaris variants. 2015-01-07 19:07:12 -05:00
Toshio Kuratomi
5354df8643 s/nexentaStor/Nexenta/ 2015-01-07 15:18:52 -08:00
Toshio Kuratomi
04635333d0 Update fact gathering for solaris-family distributions 2015-01-07 14:38:16 -08:00
Brian Coca
058816237a updated submodule refs 2015-01-07 13:48:08 -05:00
Toshio Kuratomi
6305864cca Merge pull request #9814 from ccciudatu/devel
run_once tasks are skipped without checking the delegate_to host #9784
2015-01-07 09:33:21 -08:00
Toshio Kuratomi
364b5ac0ea Do a daily update of the modules 2015-01-07 08:47:09 -08:00
Adam Miller
f274234824 Only add the overhead for each iteration of cpuinfo parsing if Xen is detected 2015-01-07 08:45:14 -06:00
Adam Miller
3729259b68 don't double the count of i for LinuxHardware cpuinfo keys on
'vendor_id' and 'model name' keys

Check for Xen paravirt and handle processor facts accordingly
2015-01-06 17:14:38 -06:00
Toshio Kuratomi
eb19ff9d62 Update extras modules to fix docs building 2015-01-05 08:41:19 -08:00
Toshio Kuratomi
bac086e705 Update modules 2015-01-05 08:30:58 -08:00
sysadmin75
aff20d911c Fixes #9415 - fetch: should use hostname instead of ip for directory name 2015-01-04 15:57:48 -05:00
Brian Coca
1698b17b14 Merge pull request #8651 from ks888/enable-env-kw-at-play-level
Enable environment keyword at play level
2015-01-02 11:07:35 -05:00
Toshio Kuratomi
41399dedaf Update core modules for docker fix 2014-12-27 17:12:22 -08:00
Mick Bass
17498b58bb Add support for AWS Security Token Service (temporary credentials) to all AWS cloud modules. 2014-12-25 13:31:34 -07:00
Toshio Kuratomi
641c6a2859 Pull in apt changes 2014-12-25 00:25:51 -08:00
Luke Macken
dea0ee663f Use send instead of sendv on the systemd.journal (fixes #9886) 2014-12-24 14:37:10 -07:00
Costi Ciudatu
1ed9b6629e run_once tasks are skipped without checking the delegate_to host #9784 2014-12-24 02:22:38 +02:00
Toshio Kuratomi
5ed7a55990 Restore json import for redis as well. Switch preference to simplejson for speed 2014-12-23 13:14:14 -08:00
Rene Moser
b5e99c852e facts caching: fix missing json in jsonfile caching 2014-12-23 16:15:26 +01:00
Toshio Kuratomi
f9c203feb6 Another try at a git fetch fix 2014-12-22 15:15:29 -08:00
Toshio Kuratomi
89da873dff Fix bug in merged git refspec code 2014-12-22 12:12:25 -08:00
Toshio Kuratomi
18536d6885 Pull in new refspec param for git module 2014-12-22 11:34:45 -08:00
Brian Coca
19038a71bf Merge pull request #9419 from willthames/aws_frankfurt
There are still a couple of modules that use their own lists, but that should not prevent this merge, those should be adapted to use this list in subsequent patch
2014-12-22 08:46:20 -05:00
Jonathan Davila
a93db1948e expanded facts 2014-12-22 08:24:22 -05:00
Brian Coca
e0f72d5861 fixed json encoding issue with redis 2014-12-19 20:09:57 -05:00
Brian Coca
ed380136bc removed uneeded and posibly error producing json import
now uses utils.jsonify which does proper utf8 encoding
2014-12-19 20:05:00 -05:00
Michael Scherer
d4bf3127ec Add a explicit error when fact_caching_connection is not set
By default, jsonfile is not documented, and the error message
when fact_caching_connection is not set is a bit puzzling, so
a error message would be beeter ( documentation too ). While redis
is faster for bigger setup, jsonfile is fine for a small setup
and is easier to deploy.

The module will then stop ansible-playbook, as this match better
the philosophy of Ansible being a fail-fast system.
2014-12-19 14:36:15 +01:00
Toshio Kuratomi
64c256b356 git module now with clone parameter and update=no reverted 2014-12-17 13:46:14 -08:00
Nathan Cahill
6d785ca081 support variables with dashes - fixes #9786 2014-12-16 20:58:38 -07:00
Toshio Kuratomi
2664de55fb Fix math filters 2014-12-16 16:59:22 -08:00
Toshio Kuratomi
fa6e587654 Pull in some new fixes to core modules 2014-12-16 16:09:50 -08:00
Toshio Kuratomi
c808c8a22a Fix some of the new math filters 2014-12-16 16:09:17 -08:00
Toshio Kuratomi
7ab1e52575 Merge pull request #9832 from bcoca/math_filters
math filters!
2014-12-16 15:42:22 -08:00
Brian Coca
b07ce8b942 removed redundant math functions as jinja2 provides abs() and round()
already
2014-12-16 17:57:21 -05:00
Brian Coca
7a43d40050 math filters! 2014-12-16 17:47:50 -05:00
Toshio Kuratomi
dc8207177e Merge pull request #9830 from nathancahill/vars_prompt-no-value
Fix vars_prompt no/false default values
2014-12-16 13:42:26 -08:00
Toshio Kuratomi
d09b64884f Merge pull request #9810 from mscherer/fix_7732
Do not use the variable name as a key for the result of the module
2014-12-16 13:09:06 -08:00
Toshio Kuratomi
828adbf788 Merge pull request #9807 from swimlappy/noproxy
Request: Honor the "no_proxy" environment variable in Ansible
2014-12-16 12:53:40 -08:00
Nathan Cahill
cc5a5978ef fix vars_prompt no/false values 2014-12-16 13:43:23 -07:00
Toshio Kuratomi
d1e27fe819 Merge pull request #9805 from mscherer/fix_9395
Strip the line to filter lines composed of only whitespaces
2014-12-16 12:42:06 -08:00
Toshio Kuratomi
735c8d3c4b Update core so docs build 2014-12-16 11:51:02 -08:00
Toshio Kuratomi
07e483b0c0 Update core modules 2014-12-16 11:18:15 -08:00
Jon Hawkesworth
e37b63386c Revised following comments from Chris Church.
Now uses sha1 checksums following merge of 9688.
Also I undid the changes I made to fetch.py
win_template.py now uses conn.shell.has_trailing_slash and
conn.shell.join_path
updated integration tests.
2014-12-16 04:47:01 +00:00
root
bf916fb58a Adding first pass at win_copy, win_file and win_template modules. 2014-12-16 04:47:01 +00:00
Jonathan Mainguy
8278626dd0 Added distribution facts for OpenSuse 2014-12-15 11:47:42 -05:00
Michael Scherer
9b8a55032d Do not use the variable name as a key for the result of the module
Using the variable name can interfere with various systems
used to communicate between modules and ansible ( as
reported in #7732 , where ansible_facts is a reserved key for
updating the fact cache, for example ).
2014-12-14 19:27:17 +01:00
Jason Holland
eedc51f213 Add support for SSL protocol version configuration option. Also fix 2 places where the SSL version was not being set properly. 2014-12-13 21:20:33 -06:00
Jason Holland
38dbce1527 Allow Ansible to honor the "no_proxy" environment varaible. 2014-12-13 21:12:23 -06:00
Michael Scherer
b84fba4439 Strip the line to filter lines composed of only whitespaces
Fix #9395
2014-12-13 20:56:06 +01:00
Toshio Kuratomi
12968acd5f Update the core modules to pull in some fixes 2014-12-12 12:09:34 -08:00
Brian Coca
215359084b Merge pull request #9375 from mantiz/fix-osfamily-and-distribution-on-archlinux
Fix os_family and distribution on archlinux
2014-12-12 14:28:38 -05:00
Nicolas Rémond
3cf0c09ce9 Variables lookup in a template should handle properly the undefined case 2014-12-12 12:11:17 +01:00
Michael Scherer
7bffc1a29e add a default path in ~/.ansible to place plugins, so ansible is a bit
more usable out of the box as simple user
2014-12-11 23:33:51 +01:00
jszwedko
462471209e Allow retries to be templatable
Fixes #5865
2014-12-10 16:54:58 -05:00
Toshio Kuratomi
2d266ce401 Update core submodule for docs fix 2014-12-10 11:22:40 -08:00
Brian Coca
21bb12ee84 updated refs to module repos 2014-12-10 14:06:48 -05:00
Toshio Kuratomi
c16b83af14 Updat ecore to pull in new git module fixes 2014-12-09 09:09:29 -08:00
Toshio Kuratomi
35cfeefdc1 Update core modules 2014-12-09 08:03:07 -08:00
Toshio Kuratomi
55cb55d67a Update the extras submodules to latest 2014-12-09 08:01:31 -08:00
Brian Coca
c725aa5e47 updated submodule refs 2014-12-08 17:28:30 -05:00
Michael DeHaan
d4da58e102 Merge pull request #9720 from vlajos/typofixes-vlajos-20141204
typofixes - https://github.com/vlajos/misspell_fixer
2014-12-08 14:00:52 -08:00
Toshio Kuratomi
3a5aec9743 file does not exist is not an error when checksumming for the template modules 2014-12-08 13:08:26 -08:00
Toshio Kuratomi
f2d2f425ae Fix comment 2014-12-08 13:07:34 -08:00
Toshio Kuratomi
3269a349f3 Fix remote_checksum with delegate_to and add tests for several ways that delegate_to works 2014-12-08 12:44:44 -08:00
Toshio Kuratomi
2a288141d3 Fix template module to fail if remote checksumming failed 2014-12-08 10:55:04 -08:00
Toshio Kuratomi
b042fcc349 Fix for delegate_to with hosts that aren't in inventory 2014-12-05 12:35:43 -08:00
Veres Lajos
bf5d8ee678 typofixes - https://github.com/vlajos/misspell_fixer 2014-12-04 22:23:35 +00:00
Toshio Kuratomi
3b80f63e22 Have known_hosts function use the url parameter instead of getting a specific attribute out of the module dict.
This makes the function useful in more places
2014-12-04 11:39:35 -08:00
Brian Coca
97408fe5b2 Revert "Make listify respect the global setting for undefined variables."
This 'mostly' reverts commit 2769098fe7.

Conflicts:
	lib/ansible/utils/__init__.py
	test/units/TestUtils.py
2014-12-04 09:14:53 -05:00
Brian Coca
e938f554b7 better exception handling for unexpected exceptions 2014-12-04 08:01:38 -05:00
Toshio Kuratomi
ae17b993d9 Update modules to allow USAGE as a valid grant option for postgres 2014-12-03 14:43:46 -08:00
Toshio Kuratomi
a2b2e54992 Fix checksum code to work with delegate_to/local_action
Fixes #9704
2014-12-03 14:43:03 -08:00
James Keener
4dfd86d847 Issue-9704 Better handling of missing python
When they python interpreter is set incorrectly for the machine the file
is being checked for (e.g. for the local or the remote), the error
manifests as a readability or directory missing error which can be very
misleading.
2014-12-03 17:15:00 -05:00
Brian Coca
1c5f625295 corrected exception name 2014-12-03 14:19:11 -05:00
Toshio Kuratomi
1ec8b6e3c5 Have remote_expanduser honor sudo and su users.
Fixes #9663
2014-12-03 10:46:56 -08:00
James Cammarata
f1386bb114 Use more variable sources when templating the play ds
Fixes #9699
2014-12-03 12:44:32 -06:00
Toshio Kuratomi
eeec4f73e7 Pull in doc fixes for modules 2014-12-03 08:18:39 -08:00
Toshio Kuratomi
05435f380b Update to newer core and extras modules 2014-12-03 07:17:43 -08:00
Brian Coca
61a30e5f49 better exception handling with delegated hosts 2014-12-03 07:26:42 -05:00
Devin Christensen
8130ed8de0 Allow .gitkeep in the jsonfile fact cache dir 2014-12-02 22:34:58 -07:00
Chris Church
2bf269568b Merge pull request #9688 from cchurch/fix_win_fetch
Fixes for fetch module when connecting to Windows hosts
2014-12-02 15:15:06 -05:00
Brian Coca
84bcc6a123 Merge pull request #9685 from bcoca/plugin_load_precedence
changed plugin load priority to be path based, not suffix based.
2014-12-02 14:45:39 -05:00
James Cammarata
29d41bb789 Revise patch from earlier using even more variable sources for HostVars
Superceeds e61e8a3

Fixes #9684
2014-12-01 21:44:42 -06:00
Chris Church
de267b5655 Fix PowerShell plugin issues affecting fetch module when used against Windows hosts. 2014-12-01 22:18:35 -05:00
Brian Coca
f2b853f7a0 changed plugin load priority to be path based, not suffix based. 2014-12-01 17:36:57 -05:00
James Cammarata
6570a6c6de Use additional vars when templating included file names
Fixes #9669
2014-12-01 15:00:14 -06:00
Toshio Kuratomi
86b21a1b8d Integration tests for https://github.com/ansible/ansible-modules-core/issues/416 2014-12-01 10:46:22 -08:00
James Cammarata
e61e8a37f5 Use extra vars when creating HostVars
Fixes #9667
2014-12-01 11:51:09 -06:00
Thomas Quinot
23d959db71 Report location (filename and line number) for inventory syntax errors
When AnsibleError is raised for a syntax error in an inventory file,
report filename and line number to help pinpointing the error.
2014-11-30 10:41:09 +01:00
Brian Coca
60b51ef6c3 Merge pull request #9646 from bcoca/listify_template_fixes
fine tuned lookup/templating errors
2014-11-26 22:20:33 -05:00
Brian Coca
9a5cbf747a fine tuned lookup/templating errors 2014-11-26 22:06:37 -05:00
Toshio Kuratomi
ae054dbc40 Pull in a fix for specifying a single role attribute for postgresql users 2014-11-26 14:46:45 -08:00
Toshio Kuratomi
0752549f02 Merge pull request #9640 from hkariti/premature_template_playbook_vars
Don't template play vars by themselves, it's too early
2014-11-26 10:54:29 -08:00
Toshio Kuratomi
4afa7ca1b1 Refresh the core modules to pull in mysql fix 2014-11-26 08:35:32 -08:00
Hagai Kariti
bc505050b0 Don't template play vars by themselves, it's too early 2014-11-26 15:45:38 +02:00
Baptiste Mathus
a1adff4ff0 Setting LC_MESSAGES: prevent unparseable messages
This locale variable defines how tools should display their messages.
This is for example gonna change the yum message from "Nothing to do" to
"Rien a faire" in my case (french).

As the yum module parses that string in err, if the message is not
enforced in english this is gonna fail.

So this commits just enriches a bit more the code that's already written
for that enforcement.

This commit fixes issue #9635.
2014-11-26 11:02:25 +01:00
Toshio Kuratomi
704f7d7b40 Fix for a traceback in the git module 2014-11-25 16:23:12 -08:00
Toshio Kuratomi
b992a18378 Really update to a newer core module version :-) 2014-11-25 15:35:16 -08:00
James Cammarata
75d05168e6 Bumping files for 1.9 2014-11-25 16:49:45 -06:00
Brian Coca
90a6c82d55 Merge pull request #9626 from bcoca/minor_template_fixes
fixes to template function
2014-11-25 16:35:46 -05:00
Brian Coca
db145a368d now only flattened ignores failonundefined cause of it's special need 2014-11-25 16:12:15 -05:00
James Cammarata
968c56d765 Expand playbook_dir in time for loading tasks
Fixes #9618
2014-11-25 13:01:08 -08:00
Brian Coca
e3feb104c3 fixes issues with listyfing failing too often 2014-11-25 15:55:53 -05:00
Brian Coca
7d2937b1cc minor fixes to template function
- make sure it calls itself correctly, now passes same params as it recieves
- vars is reserved, changed for templatevars to avoid confustion
- forcing mustaches again since the removal broke 'listification' as per #9622
- fixes incorrectly successful tests using undefined var, now it is defined
- now returns empty list if items is None to avoid errors
2014-11-25 12:59:13 -05:00
Toshio Kuratomi
9a77aefc33 Special case the lone asterisk fragment in mysql 2014-11-25 08:06:15 -08:00
Toshio Kuratomi
199d6c0b8b Fix some problems with the generic quote char 2014-11-25 02:30:32 -08:00
Toshio Kuratomi
8e7447962e Update the modules to pull in mysql identifier escaping 2014-11-25 01:47:30 -08:00
Toshio Kuratomi
fcf0975c90 Fix a few mysql related typos 2014-11-25 01:47:07 -08:00
Toshio Kuratomi
0287e9a23d Normalize the identifier quoting so we can reuse the functions for mysql 2014-11-25 00:45:59 -08:00
Toshio Kuratomi
19606afe5f Update postgresql modules so that we get all the quoting of identifier
fixes
2014-11-24 22:57:41 -08:00
Toshio Kuratomi
64a8ad9a21 Remove debugging code 2014-11-24 21:02:24 -08:00
Toshio Kuratomi
067112b5ee Code for modules to perform more robust quoting of database identifiers 2014-11-24 20:55:44 -08:00
Marc Abramowitz
e8716fcbc8 Display more info when SSH errors occur 2014-11-24 00:04:59 -08:00
Chris Church
e9b6aaf5d8 Update PowerShell command line processing to handle parameters passed via splatting. 2014-11-23 22:53:10 -05:00
Chris Church
de2746ae86 Set delegate on connection prior to calling connect. 2014-11-23 21:49:33 -05:00
Kishin Yagami
ac4dc1f739 enable environment keyword at play level 2014-11-22 10:41:13 +09:00
Brian Coca
5e33db3b7e Merge pull request #9573 from bcoca/jsonfile_cache
a cache plugin that stores facts persistently in local json dumps
2014-11-20 16:34:47 -05:00
Toshio Kuratomi
f6f02c93e7 Update to HEAD of hte modules 2014-11-20 13:23:46 -08:00
James Cammarata
4b6b58ab11 Fix role parameter precedence after 9a0f8f0
Fixes #9497
2014-11-20 12:53:48 -06:00
Brian Coca
0edaa6f790 Merge pull request #9270 from bcoca/do_the_shuffle
added new 'shuffle' filter
2014-11-20 13:43:00 -05:00
Toshio Kuratomi
11b634104f Small fix to hardlink handling in file module 2014-11-19 13:05:11 -08:00
Toshio Kuratomi
554858f3af Update core modules to pull in a git module fix 2014-11-19 12:31:38 -08:00
Toshio Kuratomi
c4c3cc315d Transform both values of a task name into a byte str prior to comparing
Fixes #9571
2014-11-19 11:50:02 -08:00
Michael DeHaan
36401fdb97 Update git submodules. 2014-11-18 17:22:58 -05:00
Michael DeHaan
f8ca975c75 The Guru program has been folded in with Ansible Tower. Have
questions or interested in Ansible support?  We'd love to hear from you.
Email us at info@ansible.com.
2014-11-18 17:20:53 -05:00
Toshio Kuratomi
0defe19c4b Update core modules for apt fix 2014-11-18 13:11:33 -08:00
Brian Coca
91b0149c52 a cache plugin that stores facts persistently in local json dumps 2014-11-18 01:05:40 -05:00
Toshio Kuratomi
25607e5cf4 When run in FIPS mode, allow vault to fail only when using legacy format 2014-11-17 16:38:56 -08:00
James Cammarata
9a0f8f0158 Split out various vars-related things to avoid merging too early
Fixes #9498
2014-11-17 15:31:55 -06:00
Michael DeHaan
2c520655ae Merge pull request #9452 from erjohnso/google_endpoint_provider
Google: allow for different libcloud provider to support upcoming DNS mo...
2014-11-17 06:57:56 -08:00
Toshio Kuratomi
c3c6a07e65 Update apt test for newer version of test package and pull in an apt module fix 2014-11-14 10:02:21 -08:00
Toshio Kuratomi
b95475c1f9 Unittest the get_split_image_tag function in the docker module 2014-11-14 08:48:21 -08:00
Brian Coca
dd60036fb9 added changed status to return when new early create check is triggered,
added skipped check to test on create existing
2014-11-14 11:13:36 -05:00
Toshio Kuratomi
11e79d9627 Update core modules to pull in latest apt fixes 2014-11-14 07:52:51 -08:00
Brian Coca
e79acf3f88 Merge pull request #9261 from jonhadfield/skip-unarchive3
Fix issue whereby file will be transferred before checking the creates argument
2014-11-13 19:21:55 -05:00
Brian Coca
504995bda2 allow fact objects to be instantiated w/o triggering all fact collection
this opens the ability to do specific facts at much lower cost.
2014-11-13 18:32:27 -05:00
Jon Hadfield
697582fdde Fix issue whereby file will be transferred before checking the creates argument. 2014-11-13 20:20:08 +00:00
Brian Coca
0990a71ab5 Merge pull request #9516 from 0x44/new-regions
Support new AWS regions: cn-north-1, eu-central-1.
2014-11-12 16:42:28 -05:00
Toshio Kuratomi
b828b25784 Add a fips fact and use it for integration tests 2014-11-12 09:29:21 -08:00
James Cammarata
5bc81f9ae7 Add ability to detect prompts in stdout from run_command 2014-11-12 11:06:15 -06:00
Brian Coca
395952329a Merge pull request #9529 from sivel/env-nested-modules
Support nested modules with ANSIBLE_LIBRARY env var
2014-11-12 10:59:18 -05:00
Toshio Kuratomi
9a7eb57718 Some changes to FIPS compat since SLES implements it differently 2014-11-11 20:23:03 -08:00
Toshio Kuratomi
d4d23b1b1f Add error when checksumming will fail because python is not present on the remote.
Comments for how the remote checksumming works.

Make the checksumming marginally more robust.
2014-11-11 20:05:27 -08:00
Toshio Kuratomi
565e5bbdfc Fix up the new expand_user method.
quoting anywhere in the user_home_path interferes with shell expansion
so we have to check it for validity ourselves.
2014-11-11 13:54:03 -08:00
Toshio Kuratomi
bc4272d2a2 Expand tilde remotely in action plugins 2014-11-11 12:28:19 -08:00