Setup Go with ansible for Golang programming


Are you familiar with Ansible ?

Then, this article is for you.


IF you are not familiar with Ansible, you can master Ansible in 2 hours by watching this course:

Bias for action

ansible-galaxy install abdennour.golang

2. Write a playbook that imports the role :

- hosts: localhost # if you want to target another host, change it
- import_role:
name: abdennour.golang
become: yes
golang_version: "1.14"
- "YOUR_USERNAME" # "{{ ansible_ssh_user}}" might be suitable

3. Run it :

ansible-playbook ./yourfile_above.yaml

You did it !! Done ! Done ! Done

4. Validate

go version


Software engineer, Cloud Architect, 5/5 AWS|GCP|PSM Certified, Owner of

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store