Commit graph

71 commits

Author SHA1 Message Date
willthames
6219fc4932 env-setup no longer needs to be run from the ansible directory, it can be run from anywhere
env-setup now takes a -q argument to run in quiet mode
2012-07-30 13:18:28 +10:00
Michael DeHaan
738cea9c93 small tweaks to --help for hacking/test-module 2012-07-23 19:33:26 -04:00
Michael DeHaan
fc96b88205 Teach the test-module script about the new way MODULE_ARGS works in new-style modules. 2012-07-23 19:28:43 -04:00
bradobro
e8583833a7 test-module uses optparse with --debugger
Refactored hacking/test-module

1. uses optparse

2. has --debugger option

tested only with pdb on Python 2.7
2012-07-23 16:28:06 +00:00
bradobro
ade0233d57 Refactoring test-module to be more like ansible. 2012-07-23 16:04:28 +00:00
Michael DeHaan
d0f4358730 Port the copy module over to the new "common module" logic. 2012-07-21 17:07:42 -04:00
Michael DeHaan
a94ec130d2 Common module code upgrades 2012-07-17 23:09:57 -04:00
Michael DeHaan
9006d4557d Added code to allow insertion of boilerplate into modules to make them able to share lots of code, the result
should be a huge reduction of total ansible source, at a slight cost of difficulty in original module development.

We need to apply this now to all modules, but may need to have some exemptions to things like command, which should
subclass this module.
2012-07-17 22:34:52 -04:00
Michael DeHaan
867b2437cc consolidate output code in callbacks.py, from utils, remove extra functions 2012-07-15 10:12:49 -04:00
Peter Sankauskas
f9a14cfec1 Adding a missing '~' to use the user's home directory instead of the root file system for the module arguments 2012-05-02 09:50:20 -07:00
Michael DeHaan
6341361a5b Clarify that stderr WILL crash your module. Can't redirect because if we do we lose tracebacks
from modules remotely when they fail to parse, and this is VERY useful data.
2012-04-27 01:36:31 -04:00
Michael DeHaan
36e454c52f Because paramiko using a pty can't distinguish stderr and stdout, remove handling that
treated -D as a way to show stderr, and make sure modules don't include things on stderr.
Update docs and test module script to come into line.
2012-04-27 01:25:38 -04:00
Michael DeHaan
533c2c6126 Make it possible to use facts from hosts in templates for other hosts.
It works like this:

{{ hostvars['127.0.0.1']['ansible_eth0']['ipv4']['address'] }}
2012-04-21 12:45:37 -04:00
Tim Bielawa
e9e8417735 Update hacking with MANPATH. Correct hacking README details. 2012-04-17 10:53:32 -04:00
Michael DeHaan
82bd75c1e0 Update env-setup script to make it work better 2012-03-18 12:28:22 -04:00
Michael DeHaan
be55145a1e Initial crack at the file module 2012-03-15 21:53:14 -04:00
Michael DeHaan
a735dd2b17 Added the 'test-module' script, useful for testing modules without running them in Ansible. 2012-03-14 21:49:27 -04:00
Michael DeHaan
85e0de5bb2 Move print statements out of playbook.py and back into CLI so we can simplify playbook operations
independent of output, and can also see all the output nicely grouped together if we want
to reformat it or make summaries of statistics.
2012-03-06 19:24:36 -05:00
Tim Bielawa
c5f8bc9d79 Don't set ANSIBLE_HOSTS inside the env-setup script 2012-03-05 16:12:05 -05:00
Tim Bielawa
f2c2786a14 Update constants.py to pull module path and the hosts file from the
environment (ANSIBLE_{LIBRARY,HOSTS}) if defined.

Update manpages to represent this.

Also update the env-setup script to set ANSIBLE_{LIBRARY,HOSTS}.
2012-03-05 16:08:36 -05:00
Tim Bielawa
6343aa6214 Add environment updating script 'env-setup' to facilitate running ansible from a git checkout. 2012-03-05 13:47:01 -05:00