--- - name: create deploy directory sudo: true file: path=/var/www/{{ app_name }}/shared/config owner={{ deploy_user }} group={{ deploy_user }} recurse=yes state=directory - name: copy database.yml template: src=database.yml dest=/var/www/{{ app_name }}/shared/config/database.yml owner={{ deploy_user }} group={{ deploy_user }} - name: copy secrets.yml template: src=secrets.yml dest=/var/www/{{ app_name }}/shared/config/secrets.yml owner={{ deploy_user }} group={{ deploy_user }}