Skip to content

Latest commit

 

History

History
42 lines (29 loc) · 1.19 KB

File metadata and controls

42 lines (29 loc) · 1.19 KB

cookiecutter-ansible-golang-module

Template for making your own cross-platform ansible module in golang.

asciicast

Usage

Prerequisites

If you use the defaults, you can run this to try out the cookiecutter template:

cruft create https://github.com/jamesandariese/cookiecutter-ansible-golang-module
cd ansible-generate_prime
bash rebuild.sh
ansible-doc -t module acme.samples.generate_prime

This will create a samples collection in the acme namespace. In that collection, there will be a generate_prime module which you can use in any ansible playbook after running rebuild.sh.

Cookiecutter

For using cookiecutter instead of cruft, use the following instead:

cookiecutter https://github.com/jamesandariese/cookiecutter-ansible-golang-module

LICENSE

Ensure you update your license if you want to use something other than MIT.