Signed-off-by: Julien Riou <julien@riou.xyz>
This commit is contained in:
commit
4a57f01124
73 changed files with 3381 additions and 0 deletions
34
roles/golang/README.md
Normal file
34
roles/golang/README.md
Normal file
|
|
@ -0,0 +1,34 @@
|
|||
# Ansible Role Go
|
||||
|
||||
Install [Go](https://go.dev/).
|
||||
|
||||
## Table of content
|
||||
|
||||
<!-- ANSIBLE DOCSMITH TOC START -->
|
||||
* [Role variables](#variables)
|
||||
* [`golang_version`](#variable-golang_version)
|
||||
<!-- ANSIBLE DOCSMITH TOC END -->
|
||||
<!-- ANSIBLE DOCSMITH MAIN START -->
|
||||
|
||||
## Role variables<a id="variables"></a>
|
||||
|
||||
The following variables can be configured for this role:
|
||||
|
||||
| Variable | Type | Required | Default | Description (abstract) |
|
||||
|----------|------|----------|---------|------------------------|
|
||||
| `golang_version` | `str` | No | `"1.25.4"` | Version to install. |
|
||||
|
||||
### `golang_version`<a id="variable-golang_version"></a>
|
||||
|
||||
[*⇑ Back to ToC ⇑*](#toc)
|
||||
|
||||
Version to install.
|
||||
|
||||
- **Type**: `str`
|
||||
- **Required**: No
|
||||
- **Default**: `"1.25.4"`
|
||||
|
||||
|
||||
|
||||
|
||||
<!-- ANSIBLE DOCSMITH MAIN END -->
|
||||
8
roles/golang/defaults/main.yml
Normal file
8
roles/golang/defaults/main.yml
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
---
|
||||
|
||||
# Version to install.
|
||||
#
|
||||
# - Type: str
|
||||
# - Required: No
|
||||
# - Default: 1.25.4
|
||||
golang_version: 1.25.4
|
||||
13
roles/golang/meta/argument_specs.yml
Normal file
13
roles/golang/meta/argument_specs.yml
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
---
|
||||
argument_specs:
|
||||
main:
|
||||
short_description: Install Go
|
||||
description:
|
||||
- Install [Go](https://go.dev/).
|
||||
author:
|
||||
- jriou
|
||||
options:
|
||||
golang_version:
|
||||
description:
|
||||
- Version to install.
|
||||
default: 1.25.4
|
||||
7
roles/golang/tasks/main.yml
Normal file
7
roles/golang/tasks/main.yml
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
---
|
||||
- name: Install
|
||||
ansible.builtin.unarchive:
|
||||
src: "https://go.dev/dl/go{{ golang_version }}.linux-amd64.tar.gz"
|
||||
dest: /usr/local
|
||||
remote_src: true
|
||||
creates: /usr/local/go
|
||||
Loading…
Add table
Add a link
Reference in a new issue