# using ansible when sftp is not available

**URL:** <https://forum.ansible.com/t/using-ansible-when-sftp-is-not-available/21093>\
**Category:** Ansible Project\
**Created:** [April 7, 2016, 1:58pm UTC](https://forum.ansible.com/t/using-ansible-when-sftp-is-not-available/21093 "2016-04-07T13:58:54Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Craig\_Wilson](https://avatars.discourse-cdn.com/v4/letter/c/eb9ed0/32.png) [@Craig\_Wilson](https://forum.ansible.com/u/Craig_Wilson)\
**Post date:** [April 7, 2016, 1:58pm UTC](https://forum.ansible.com/t/using-ansible-when-sftp-is-not-available/21093/1 "2016-04-07T13:58:54Z")

</div>

Hi all

We are looking into ansible and one of the things we would like to do is issue a few commands to some storage appliances that we have. They are looked down and as such we can not access sftp or even scp just ssh into their custom command line interface.

I’m testing this and I’ve managed to get raw module working to retrieve information, as below:

`

---

<div class="post-metadata">

**Author:** ![David\_Williams1](https://avatars.discourse-cdn.com/v4/letter/d/e274bd/32.png) [@David\_Williams1](https://forum.ansible.com/u/David_Williams1)\
**Post date:** [February 27, 2017, 11:14pm UTC](https://forum.ansible.com/t/using-ansible-when-sftp-is-not-available/21093/2 "2017-02-27T23:14:20Z")

</div>

Did you ever find a solution to this? I’m having the same issue. Does the expect module really generate a python file, send it to the remote host, and execute it there to pull this off? Can’t it just execute like an expect script locally?

---

<div class="post-metadata">

**Author:** ![Kai\_Stian\_Olstad](https://avatars.discourse-cdn.com/v4/letter/k/e19adc/32.png) [@Kai\_Stian\_Olstad](https://forum.ansible.com/u/Kai_Stian_Olstad)\
**Post date:** [February 28, 2017, 7:46am UTC](https://forum.ansible.com/t/using-ansible-when-sftp-is-not-available/21093/3 "2017-02-28T07:46:17Z")

</div>

> I'm having the same issue. Does the  
> expect module really generate a python file, send it to the remote host,  
> and execute it there to pull this off?

Yes, it does if you don't tell it not to do it.

> Can't it just execute like an expect script locally?

Yes, just use "delegate\_to: localhost" on the task and expect will run on the Ansible controller host.
