Skip to content

Commit

Permalink
Merge pull request #154 from Lumbendil/fix-git-response-register
Browse files Browse the repository at this point in the history
Fix ansistrano_git_result register
  • Loading branch information
ricardclau authored Sep 21, 2016
2 parents e22682a + 109ac9d commit 86a24ff
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions tasks/update-code/git.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
accept_hostkey: true
update: yes
force: yes
register: ansistrano_git_result
register: ansistrano_git_result_update
when: ansistrano_git_identity_key_path|trim == ''

- name: ANSISTRANO | GIT | Update remote repository using SSH key
Expand All @@ -26,9 +26,12 @@
update: yes
force: yes
key_file: "{{ ansistrano_deploy_to }}/git_identity_key"
register: ansistrano_git_result
register: ansistrano_git_result_update_ssh
when: ansistrano_git_identity_key_path|trim != ""

- name: ANSISTRANO | GIT | Register ansistrano_git_result variable
set_fact: ansistrano_git_result={{ ansistrano_git_result_update_ssh if ansistrano_git_result_update|skipped else ansistrano_git_result_update }}

- name: ANSISTRANO | GIT | Shred GIT deployment key
command: shred -f "{{ ansistrano_deploy_to }}/git_identity_key"
when: ansistrano_git_identity_key_path|trim != ""
Expand Down

0 comments on commit 86a24ff

Please sign in to comment.