James Tanner
9169a11088
Fixes #4777 add --force-handlers option to run handlers even if tasks fail
2014-03-24 10:28:48 -04:00
Herby Gillot
c0886a5f3a
Add a fact providing the full hostname, without the domain portion
...
truncated.
2014-03-23 21:59:47 -04:00
Michael DeHaan
fba2f1f9a9
Merge pull request #6639 from fvieira/devel
...
Add missing sha1 import on known_hosts.py
2014-03-23 16:23:55 -04:00
Michael DeHaan
a24d3f78d9
Merge pull request #6634 from pilou-/fix
...
Remove print statements
2014-03-23 16:12:04 -04:00
James Cammarata
31628d86a1
Adding in a configurable option for the accelerate daemon timeout
...
This was apparently an oversite, as it has never been configurable
despite having a module parameter for the timeout.
2014-03-23 14:45:49 -05:00
James Cammarata
3ea5d573aa
Acclerate improvements
...
* Added capability to support multiple keys, so clients from different
machines can connect to a single daemon instance
* Any activity on the daemon will cause the timeout to extend, so that the
daemon must be idle for the full number of minutes before it will auto-
shutdown
* Various other small fixes to remove some redundancy
Fixes #5171
2014-03-23 14:45:49 -05:00
Francisco José Marques Vieira
e9d7476c28
Add missing sha1 import on known_hosts.py
2014-03-23 17:19:23 +00:00
Pierre-Louis Bonicoli
d3a470db0c
Remove print statements
...
"print item" raises an exception when type of item is
jinja2.runtime.StrictUndefined
2014-03-23 03:58:44 +01:00
James Tanner
5b3b9ba267
Addresses #4407 Caculate failed percentage based on serial and number of hosts in play
2014-03-21 13:31:47 -04: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
Joshua Conner
1c504eff68
etcd lookup: use $ANSIBLE_ETCD_URL if it exists in the env
2014-03-20 15:16:28 -07:00
James Tanner
14499e8bf3
Fixes #4325 allow async and poll parameters to be templated vars
2014-03-20 16:09:58 -04: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
James Tanner
95c79ad483
Fixes #4239 merge injects with new vars loaded from files
2014-03-20 13:12:33 -04:00
James Tanner
d327e3d11a
Fixes #5622 included tasks in roles now inherit tags from the role
2014-03-20 11:56:13 -04:00
Till Maas
898a38b074
module_utils/atomic_move(): Use tempfile module
...
Fix a potential race condition by using the tempfile module.
2014-03-20 12:34:19 +01:00
Till Maas
8f778a83df
module_utils/atomic_move(): Restore owner/group
...
Manually restore owner and group if both src and dest are on a separate
file system.
2014-03-20 12:34:19 +01:00
Michael DeHaan
e639b5382b
Change default gathering policy, add to docs.
2014-03-19 18:03:03 -04:00
Brian Coca
18adf07fc6
changed setting values and updated docs
2014-03-19 18:03:03 -04:00
Brian Coca
4dfa40f18e
added gathering control to ansible, defaults to 'smart'
2014-03-19 18:03:03 -04:00
Michael DeHaan
c42dbf80a2
Merge pull request #6586 from sivel/probline-logic-fix
...
Fix logic in process_common_errors for unbalanced quotes
2014-03-19 17:45:49 -04:00
James Tanner
b8f627d1d5
Prevent rewriting the encrypted file if decryption fails
2014-03-19 16:31:03 -04:00
James Tanner
e71857fbdf
Addresses #6579 Only strip vault passwords if given
2014-03-19 16:08:35 -04:00
James Tanner
8c2e1e2baa
Addresses #6579 Disallow vault passwords with newline characters by stripping them in utils
2014-03-19 15:56:14 -04:00
James Cammarata
a9000e7f3a
Making the error messages for bad key/dir permissions more understandable
...
Fixes #6254
2014-03-19 14:09:03 -05:00
Matt Martz
2aaecc5afa
Fix logic in process_common_errors for unbalanced quotes
2014-03-19 13:49:31 -05:00
James Cammarata
4880cfb5ea
Merge pull request #6568 from sivel/ssl-cert-validation-osx
...
Make SSL verification on Mac OS X work out of the box
2014-03-19 13:45:45 -05:00
James Tanner
67517e96d3
Fixes #6567 put the git wrapper script in the module temp dir
2014-03-19 10:30:10 -04:00
Matt Martz
1d3d73a0b6
Only write the DUMMY_CA_CERT on OS X
2014-03-19 09:01:13 -05:00
Matt Martz
3b5aa8bd30
Provide a dummy ca to allow OS X to do it's OpenSSL keychain magic
2014-03-18 17:16:44 -05:00
James Cammarata
eb7717aa02
Make sure all tags are in a list before merging for role deps
...
Fixes #6557
2014-03-18 12:32:22 -05:00
James Cammarata
c9fcbf7bdd
Change print message to vvv for missing known hosts in ssh.py
2014-03-18 12:26:10 -05:00
James Tanner
49807877fa
Fixes #6550 Use shell for pipe lookup subprocess.popen calls
2014-03-18 12:21:26 -04:00
James Cammarata
3f5440f7df
Make modules set a valid working directory
...
Fixes #6546
2014-03-18 10:37:52 -05:00
James Cammarata
84908a57fc
Don't filter role deps on tags
...
Also, fixed a bug where the tags were being merged into the wrong
data structure (passed_vars) in _build_role_dependencies()
Fixes #6439
Fixes #5709
2014-03-17 23:03:16 -05:00
Michael DeHaan
9da26da335
Merge branch 'ini_vars' of git://github.com/dmage/ansible into devel
2014-03-17 17:37:57 -04:00
Michael DeHaan
13f69dad05
Merge pull request #6527 from patrickheeney/hosts-bug
...
Fix for hostkey directory
2014-03-17 17:35:27 -04:00
Michael DeHaan
94e3350b38
Catch a unquoted line error. Fixes #6532
2014-03-17 17:15:42 -04:00
jctanner
b8d5ba42f5
Merge pull request #6523 from sergevanginderachter/vault-in-subdirs
...
Pass through vault_password when parsing host/group vars as directories.
2014-03-17 17:06:41 -04:00
James Cammarata
c4f1c3c6b0
Merge branch 'bcoca-file_fixes_clean' into devel
2014-03-17 16:02:33 -05:00
James Tanner
ad70e9bcd6
Fixes #6227 skip non-unicode strings and catch decode errors silently in template_from_string
2014-03-17 16:54:25 -04:00
James Tanner
20262b6c15
Remove unused variable in _executor_internal
2014-03-17 15:53:48 -04:00
James Cammarata
5d8c9d3f0f
Merge branch 'file_fixes_clean' of https://github.com/bcoca/ansible into bcoca-file_fixes_clean
2014-03-17 14:03:26 -05:00
James Cammarata
7edee91aba
Fixing a bug in role tag handling where only the first tag was used
...
Fixes #6517
2014-03-17 11:28:54 -05:00
James Tanner
ebb6b8442b
Catch unicode unescape failures in copy action plugin
2014-03-17 12:14:29 -04:00
patrickheeney
a9aab23f11
Fix for hostkey directory
2014-03-17 09:00:08 -07:00
James Tanner
b14c658532
Fix concatenation for with_file
2014-03-17 10:38:22 -04:00
Serge van Ginderachter
280498a7e5
Pass through vault_password when parsing host/group vars as directories.
...
Fixes a bug where vault_password parameter was not passed through in
_load_vars_from_folder()
modified: lib/ansible/inventory/vars_plugins/group_vars.py
2014-03-17 10:51:04 +01:00
Greg Dallavalle
77229553a3
fetch_url: Avoid credential stripping for FTP-scheme URLs
2014-03-16 20:41:03 -05:00
Michael DeHaan
fe696e4720
Merge commit.
2014-03-16 17:08:26 -04:00
Michael DeHaan
b41541c62a
Merge conflict.
2014-03-16 16:48:03 -04:00
Michael DeHaan
fd0ff6f174
Merge pull request #5711 from sivel/plugin-realpath
...
Use realpath for plugin directories instead of abspath
2014-03-16 15:42:47 -05:00
Michael DeHaan
6144c5e1e2
Merge pull request #5714 from eggsby/patch-2
...
Allow templates in ansible_sudo_pass inventory var
2014-03-16 15:42:12 -05:00
Michael DeHaan
b0dbc61d63
Move facts to 'module_utils' so they can be referenced by other modules. Note unlike other module_utils/ dirs this keeps the original
...
license -- so usage of facts code in modules will be limited to GPLv3 modules.
2014-03-16 16:12:02 -04:00
Michael DeHaan
b8f1e4f765
Merge pull request #6134 from veeti/include_with_items_path
...
Show the offending file name with the include + with_items error
2014-03-16 15:10:31 -05:00
Michael DeHaan
4a06954a13
Merge pull request #6390 from sergevanginderachter/group-varsdirs-svn
...
group_vars plugin: do not parse hidden files in subfolders
2014-03-16 14:44:17 -05:00
Michael DeHaan
9cdbc53741
Merge pull request #6420 from bcoca/role_names
...
added new role_names variable that exposes current roles list
2014-03-16 14:42:40 -05:00
Michael DeHaan
26efc7ace8
Revert "Populate module_setup from the setup module rather than special code elsewhere"
...
This reverts commit 58eec2e4c2
.
2014-03-16 14:11:43 -04:00
Oleg Bulatov
f6a4c20cc0
Make parsing variables for hosts and groups more consistent
...
This commit allows to specify arrays in [group:vars] block.
Signed-off-by: Oleg Bulatov <oleg@bulatov.me>
2014-03-16 21:47:26 +04:00
Michael DeHaan
a9896afc66
Merge pull request #6418 from bcoca/template_itnore_errors
...
templates ignore_errors
2014-03-16 12:44:51 -05:00
Michael DeHaan
d5856bd475
Merge pull request #6391 from sergevanginderachter/hashmerge_inventoryscripts
...
Allow hash_behaviour=merge to be respected in core inventory
2014-03-16 12:42:35 -05:00
Dag Wieers
58eec2e4c2
Populate module_setup from the setup module rather than special code elsewhere
...
This small change allows for individual setup actions to populate the SETUP_CACHE and not cause a subsequent facts-gathering when not needed. This follows the standard of other facts modules as laid out in #1206 and implemented in fedfd18774
. It allows to test of the setup module has already been run even when gather_facts was explicitely disabled.
2014-03-16 13:37:07 -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
Cristian Ciupitu
a7da5d8702
Micro-optimization of inventory.expand_hosts.detect_range
2014-03-16 13:10:28 -04:00
Brian Coca
2d25577e11
Fixes and cleanup to file functions and module
...
- unified set attribute functions ... not sure why 2 identical functions
exist with diff names, now there are 3 while i repoint all modules to 1
- fixed issue with symlinks being created w/o existing src when force=no
- refactored conditionals, simplified where possible
- added tests for symlink to nonexistant source, with both force options
- made symlink on existing attomic (force)
2014-03-15 13:54:24 -04:00
James Cammarata
a0cb974575
Be sure to return to the old directory if cwd is set in run_command
2014-03-13 16:24:29 -05:00
James Tanner
a348f67238
Reset the current directory after running subprocess.Popen
2014-03-13 17:15:23 -04:00
James Cammarata
677008bef7
Rejoin args list into a string for run_command when using an unsafe shell
...
This allows the use of an args list with leading environment variables,
which otherwise would fail due to the way Popen works.
2014-03-13 14:31:32 -05:00
James Cammarata
5233d4bc31
Fix typo in run_command when sending data that is not binary
2014-03-13 14:28:51 -05:00
James Cammarata
b1a37dcc08
Revert "Rejoin args list into a string for run_command when using an unsafe shell"
...
This reverts commit 4273cb2d8e
.
2014-03-13 14:04:51 -05:00
James Cammarata
4273cb2d8e
Rejoin args list into a string for run_command when using an unsafe shell
...
This allows the use of an args list with leading environment variables,
which otherwise would fail due to the way Popen works.
2014-03-13 13:51:59 -05:00
Michael DeHaan
d1753046e0
Revert "Correctly catch template errors without returning invalid data"
...
This reverts commit 3cd7d47b7e
.
2014-03-13 07:46:19 -04:00
James Cammarata
303e085f8b
Only use cwd in run_command kwargs if the directory exists
2014-03-12 15:59:55 -05:00
James Cammarata
60a7f57300
Make sure the cwd exists in run_command before trying to use it
2014-03-12 14:33:31 -05:00
Dan Koch
bbf320fd22
Work around for cwd stat problems with run_command and sudo
...
This fixes issue #6443
2014-03-12 14:59:50 -04:00
James Cammarata
2c7d58abe0
Compile ca certs into a temp file to reduce number of attempts
...
For those who may have a large number of certs found, this can reduce
the number of ssl connections attempted.
2014-03-12 13:45:16 -05:00
Michael DeHaan
d37f0c6d12
Use same implementation as ssh.py for "is in host file" checks in module code, prevents git module from adding keys more than once.
2014-03-12 14:11:45 -04:00
Michael DeHaan
6d841d120e
Don't process shell commands as arrays.
2014-03-12 11:57:28 -04:00
James Cammarata
86d2ee4b97
Don't append tags from roles to the plays tags list
...
Fixes #6393
2014-03-12 10:41:18 -05:00
James Cammarata
a9017af2bb
Adding validate_certs to all modules that use fetch_url
2014-03-12 10:19:54 -05:00
Michael DeHaan
cfabc2e28a
module.run_command is intended to bypass the shell here, so can't do ">>"
2014-03-12 10:57:49 -04:00
James Cammarata
7f38cff989
Remove unused code from get_ca_certs() function
2014-03-12 09:33:19 -05:00
James Cammarata
804e4166c8
Rewriting ssl validation to try multiple certs found in paths
...
Previously, the function checked only for a single CA root cert, however
some distributions may have multiple certs in a directory. This will now
try any .crt or .pem file contained within several common paths for
each platform.
Fixes #6412
2014-03-12 09:21:19 -05:00
Michael DeHaan
0b0ca95731
Expand environment variables and tildes passed to commands generically across the board.
2014-03-12 10:11:09 -04:00
James Tanner
0e38f5dfdc
Check for hash availability during vault operations
2014-03-12 09:38:29 -04:00
Brian Coca
906e59d8a8
added new role_names variable that exposes current roles list
2014-03-11 22:13:29 -04:00
Brian Coca
7778aca966
templates ignore_errors
2014-03-11 21:30:58 -04:00
James Cammarata
6c25e78299
Merge branch 'devel' of https://github.com/dparalen/ansible into dparalen-devel
2014-03-11 15:34:15 -05:00
James Tanner
e4e64a9699
Rename lxc to libvirt_lxc
2014-03-11 16:16:24 -04:00
James Cammarata
bca6adc812
Merge pull request #4064 from mscherer/lxc
...
Add a plugin that permit to use ansible for lxc system, using libvirt
2014-03-11 15:12:51 -05:00
James Cammarata
430cce9df3
Merge branch 'ec2_security_token' of https://github.com/willthames/ansible into willthames-ec2_security_token
2014-03-11 10:45:38 -05:00
Serge van Ginderachter
6b1cb22fc3
Allow hash_behaviour=merge to be respected in core inventory
...
(For now, this means, enable it also for inventory scripts)
2014-03-11 12:49:54 +01:00
Serge van Ginderachter
29c60bdaff
group_vars plugin: do not parse hidden files in subfolders, e.g. avoid .svn/
2014-03-11 12:20:58 +01:00
James Tanner
6740a1f342
Wrap crypto.hash imports with try/except
2014-03-10 19:44:08 -04:00
Michael DeHaan
411bcb7161
Merge remote branch 'real/devel' into devel
2014-03-10 19:11:21 -04:00
Michael DeHaan
2fa6110961
Update the message about pycrypto to include that python-devel must be installed.
2014-03-10 17:23:37 -04:00
James Tanner
0d6f6ad282
Implement new default cipher class AES256
2014-03-10 16:15:44 -05:00
Michael DeHaan
20f0157152
Merge pull request #6378 from franckcuny/headers-gce-utils
...
Add BSD license to module_utils/gce.py
2014-03-10 16:14:51 -05:00