Curl type download in Ansible
1- name: Download drush phar file (8.3.0)
2 become: yes
3 get_url:
4 url: https://github.com/drush-ops/drush/releases/download/8.3.0/drush.phar
5 dest: /usr/local/bin
6 mode: +x
7 checksum: sha256:ddfe6d529e44e98c2cf74c143c1fcdf67c927d6f9a5eb2ae10fbe47ef9b8eaf0
8 group: root
9 owner: root
See get_url module in https://docs.ansible.com/ansible/latest/modules/get_url_module.html