ansistrano / deploy

Ansible role to deploy scripting applications like PHP, Python, Ruby, etc. in a capistrano style
https://ansistrano.com
MIT License
2.37k stars 343 forks source link

Send git hash to revision file #288

Closed ricardclau closed 6 years ago

ricardclau commented 6 years ago

Should cover https://github.com/ansistrano/deploy/issues/285 and https://github.com/ansistrano/deploy/issues/272.

If someone else could check it out, that would be much appreciated

rromanchuk commented 4 years ago

@ricardclau struggling to utilize a clean implementation to support serial deploys

ansible-playbook -i hosts -e "ansistrano_release_version=date -u +%Y%m%d%H%M%SZ" deploy.yml

I use ansible tower/awx so i cant really interact with with the shell like you can in this context.

Maybe i could just use a filter inside the play like ansistrano_release_version: {{ '%Y%m%d%H%M%SZ' | strftime(ansible_date_time.epoch) }} seems like this should work in theory?