I’m hitting an error when I run a playbook that’s spitting out the error “module is missing interpreter line”. It’s dying on a task that uses the file module to copy a file to the remote server. I never had any trouble with this task until I tried to run the latest Ansible code in an attempt to fix an issue with a completely different task in the same playbook.
On this system I’m using the latest release branch (1.8.2) from the ubuntu PPA, but to try and fix my other failing task I copied my ansible.cfg file and adjusted the settings as necessary so I could use a cloned copy of the ansible devel branch to run the playbook instead. I started seeing this new error once I used the devel branch, so I tried to go back and re-run my playbook using the 1.8.2 version already installed on my system (using the original config file), but the error continued. The task in question (which hasn’t changed at all since I did all this, neither has anything else in the playbook) is below:
- name: install private docker registry CA cert
sudo: yes
copy:
src=…/files/docker_registry.pem
dest=/usr/local/share/ca-certificates/docker_registry.pem
owner=root
group=root
mode=0600
I thought perhaps it might be a cached setting or module on the remote system that was causing the error, so I removed the entire .ansible directory from the remote user’s home directory, but it didn’t fix the error.
Does anyone know how I can fix this?
Thanks,
Guy