I want to show you some tricks and solutions that I designed along my journey automating stuff with Ansible. To use these tricks doesn't matter if you are new in the Ansible world or already are a power user.
How to learn Ansible?
If you want to learn a lot of stuff from a really competent person, Jeff Geerling has an awesome playlist on his YouTube channel. The geerlingguy (his GitHub/Twitter name account) was part of the Ansible team and still maintaining many Ansible roles and collections. This is the best source that I can recommend for any beginner and even more advanced users today (2021).
Install Python3. Ansible requires python3 on the machine in order to work, but does exist one trick to install python3 with ansible:
Install binary from remote
A common problem that I face is installing the latest version of an application from a GitHub release, so here are two examples of how to do that.