summaryrefslogtreecommitdiffstats
path: root/scripts/sh/deploy_go.sh
diff options
context:
space:
mode:
authorGeorg Pfuetzenreuter2021-07-23 17:34:09 +0200
committerGeorg Pfuetzenreuter2021-07-23 17:34:09 +0200
commitc85c094f27483abb76a3cd4e1ed8fa8e88f3bd43 (patch)
treeb1601c0bc97f9312a3add3f078a2668de005a62b /scripts/sh/deploy_go.sh
parent1f2002a2952d5c3c72e2a8afb1bb76b3c90dd022 (diff)
downloadsystem-c85c094f27483abb76a3cd4e1ed8fa8e88f3bd43.tar.gz
system-c85c094f27483abb76a3cd4e1ed8fa8e88f3bd43.tar.bz2
system-c85c094f27483abb76a3cd4e1ed8fa8e88f3bd43.zip
Go and Ergo Deployment Scripts
Signed-off-by: Georg Pfuetzenreuter <georg@lysergic.dev>
Diffstat (limited to 'scripts/sh/deploy_go.sh')
-rwxr-xr-xscripts/sh/deploy_go.sh22
1 files changed, 22 insertions, 0 deletions
diff --git a/scripts/sh/deploy_go.sh b/scripts/sh/deploy_go.sh
new file mode 100755
index 0000000..00377dd
--- /dev/null
+++ b/scripts/sh/deploy_go.sh
@@ -0,0 +1,22 @@
+#!/bin/sh
+DISTRIB=$(awk -F= '/^NAME/{print $2}' /etc/os-release)
+echo $DISTRIB
+if [[ ${DISTRIB} = "openSUSE Leap" ]]
+echo
+then
+read -p "Deploy Go on this system? " -n 1 -r
+echo
+if [[ $REPLY =~ ^[Yy]$ ]]
+then
+if [ ! -f /etc/zypp/repos.d/go.repo ]
+then
+REPO="https://download.opensuse.org/repositories/devel:/languages:/go/openSUSE_Leap_15.3/devel:languages:go.repo"
+zypper ar --gpgcheck-allow-unsigned-repo $REPO
+fi
+zypper ref
+zypper in -y go
+echo OK
+fi
+else
+echo "This is currently only compatible with SUSE Leap nodes."
+fi