# Unable to execute a shell script in ansible

**URL:** <https://forum.ansible.com/t/unable-to-execute-a-shell-script-in-ansible/37864>\
**Category:** Ansible Developer\
**Created:** [April 7, 2023, 1:45pm UTC](https://forum.ansible.com/t/unable-to-execute-a-shell-script-in-ansible/37864 "2023-04-07T13:45:39Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Asad](https://avatars.discourse-cdn.com/v4/letter/a/848f3c/32.png) [@Asad](https://forum.ansible.com/u/Asad)\
**Post date:** [April 7, 2023, 1:45pm UTC](https://forum.ansible.com/t/unable-to-execute-a-shell-script-in-ansible/37864/1 "2023-04-07T13:45:39Z")

</div>

Hi All ,

I have a issue shell module its not executing :

shell: |  
cd /u01/{{APP\_NAME}}

scriptpass run {{APP\_NAME}} rotate-passwd FORCE\_RESET

Multiple shell scrips work is shell module except the above script

---

<div class="post-metadata">

**Author:** ![Michael\_Haskell](https://avatars.discourse-cdn.com/v4/letter/m/b9bd4f/32.png) [@Michael\_Haskell](https://forum.ansible.com/u/Michael_Haskell)\
**Post date:** [April 7, 2023, 3:23pm UTC](https://forum.ansible.com/t/unable-to-execute-a-shell-script-in-ansible/37864/2 "2023-04-07T15:23:49Z")

</div>

Try indenting the commands to the same level (indent scriptpass to the same level as cd).
