Script module failing with ansible 1.6

Hi,

since the update to ansible 1.6 the script module has been failing with "LC_CTYPE=en_US.UTF-8: Command not found." (which makes sense since it's not valid syntax for the csh shell). I didn't see anything in the changelog associated with the script module being changed.

If I execute ansible with -vvvv it shows:
<xxx.xxx.xxx.xxx> EXEC ['ssh', '-C', '-tt', '-vvv', '-o', 'ControlMaster=auto', '-o', 'ControlPersist=60s', '-o', 'ControlPath=/home/ryan/.ansible/cp/ansible-ssh-%h-%p-%r', '-o', 'StrictHostKeyChecking=no', '-o', 'Port=22', '-o', 'KbdInteractiveAuthentication=no', '-o', 'PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey', '-o', 'PasswordAuthentication=no', '-o', 'User=root', '-o', 'ConnectTimeout=10', 'xxx.xxx.xxx.xxx', u'LC_CTYPE=en_US.UTF-8 LANG=en_US.UTF-8 /root/.ansible/tmp/ansible-tmp-1399656169.24-178075505046716/install-freebsd-8_4.sh ']

I understand that in general modules would want to define the LANG and LC settings so they can reliably parse output, but according to the documentation script should perform like raw in that it just dumps the script on the destination and executes it, there is not much to parse except for the return code and output.
For now my only options are to either downgrade ansible or change my pxe rescue boot environment to use a different shell that is "compatible" with ansible.

Thanks, could you please open an issue on github for this issue so we can keep track of it?

Subject should probably be “script module failing with ansible 1.6 on csh” – others should not panic :slight_smile:

We’ve discussed this a bit and most likely we’ll have to make an inventory variable to disable the environment options for csh.