Revise go setup role and bump version

- clean go cache at the role level
- use go env GOMODCACHE for path resolution
- add become: true to prevent permission issues
- check stdout instead of stderr for go clean -x --cache
- cache cleaning is skipped by default
- fix lint errors
This commit is contained in:
ionutboangiu
2025-03-12 13:15:39 +02:00
committed by Dan Christian Bogos
parent 3545224ee6
commit 1c672c33ec
9 changed files with 50 additions and 20 deletions

View File

@@ -142,8 +142,8 @@ To install the latest Go version at the time of writing this documentation, run:
# sudo dnf install -y wget tar for .rpm distros
sudo rm -rf /usr/local/go
cd /tmp
wget https://go.dev/dl/go1.23.1.linux-amd64.tar.gz
sudo tar -C /usr/local -xzf go1.23.1.linux-amd64.tar.gz
wget https://go.dev/dl/go1.24.0.linux-amd64.tar.gz
sudo tar -C /usr/local -xzf go1.24.0.linux-amd64.tar.gz
export PATH=$PATH:/usr/local/go/bin
Installation