mirror of
https://github.com/community-scripts/ProxmoxVE.git
synced 2025-09-13 07:10:51 +02:00
[Standardization]: Same Setup for GoLang on all LXC's & Clear Tarball (#1977)
This commit is contained in:
@@ -42,10 +42,12 @@ msg_ok "Installed pnpm"
|
||||
|
||||
msg_info "Installing Golang"
|
||||
set +o pipefail
|
||||
GOLANG=$(curl -s https://go.dev/dl/ | grep -o "go.*\linux-amd64.tar.gz" | head -n 1)
|
||||
wget -q https://golang.org/dl/$GOLANG
|
||||
tar -xzf $GOLANG -C /usr/local
|
||||
ln -s /usr/local/go/bin/go /usr/local/bin/go
|
||||
temp_file=$(mktemp)
|
||||
golang_tarball=$(curl -s https://go.dev/dl/ | grep -oP 'go[\d\.]+\.linux-amd64\.tar\.gz' | head -n 1)
|
||||
wget -q https://golang.org/dl/"$golang_tarball" -O "$temp_file"
|
||||
tar -C /usr/local -xzf "$temp_file"
|
||||
ln -sf /usr/local/go/bin/go /usr/local/bin/go
|
||||
rm -f "$temp_file"
|
||||
set -o pipefail
|
||||
msg_ok "Installed Golang"
|
||||
|
||||
|
||||
Reference in New Issue
Block a user