---
- command: bower install chdir={{ project_dir }}
- command: bundle install chdir={{ project_dir }}
- command: npm install chdir={{ project_dir }}
- command: npm install chdir={{ project_dir }}/api

---
- command: bower install chdir={{ project_dir }}
- command: bundle install chdir={{ project_dir }}
- npm: path={{ project_dir }}
- npm: path={{ project_dir }}/api

Use ansible npm module instead of raw command
Use ansible npm module instead of raw command
