From 8697f00aa2014cfd1ce3d6f2f99f0551db6c0424 Mon Sep 17 00:00:00 2001 From: frrist Date: Thu, 21 Mar 2024 10:14:14 -0700 Subject: [PATCH] fix: update bacalhau install script to use go v1.21.8 --- .../modules/instance_files/install-bacalhau.sh | 15 +++++++++++++++ ops/marketplace-tf/vars.tfvars | 2 +- 2 files changed, 16 insertions(+), 1 deletion(-) diff --git a/ops/marketplace-tf/modules/instance_files/install-bacalhau.sh b/ops/marketplace-tf/modules/instance_files/install-bacalhau.sh index 156caef35e..c1a46beb39 100644 --- a/ops/marketplace-tf/modules/instance_files/install-bacalhau.sh +++ b/ops/marketplace-tf/modules/instance_files/install-bacalhau.sh @@ -111,6 +111,7 @@ function install-bacalhau-dependencies() { echo "Installing Bacalhau dependencies..." apt-update install-apt-dependencies + install-golang install-earthly } @@ -139,4 +140,18 @@ function install-earthly() { } } +function install-golang() { + # Install go + export HOME=/root + export GOCACHE="$HOME/.cache/go-build" + export GOPATH="/root/go" + export PATH="$PATH:$GOPATH/bin:/usr/local/go/bin" + sudo mkdir -p "$GOPATH" + + sudo rm -fr /usr/local/go /usr/local/bin/go + curl --silent --show-error --location --fail 'https://go.dev/dl/go1.21.8.linux-amd64.tar.gz' | sudo tar --extract --gzip --file=- --directory=/usr/local + sudo ln -s /usr/local/go/bin/go /usr/local/bin/go + go version +} + install-bacalhau "$@" \ No newline at end of file diff --git a/ops/marketplace-tf/vars.tfvars b/ops/marketplace-tf/vars.tfvars index d574eb1c40..0c6d9da247 100644 --- a/ops/marketplace-tf/vars.tfvars +++ b/ops/marketplace-tf/vars.tfvars @@ -4,7 +4,7 @@ requester_machine_type ="e2-standard-8" compute_machine_type = "e2-standard-8" compute_count = 2 -gcp_boot_image = "projects/forrest-dev-407420/global/images/bacalhau-ubuntu-2204-lts-test-latest" +gcp_boot_image = "projects/bacalhau-dev/global/images/bacalhau-v1-2-2-ubuntu-2204-lts" gcp_project_id = "forrest-dev-407420" gcp_region = "us-west1" gcp_zone = "us-west1-b"