Skip to content

Commit

Permalink
Add useful tools to provisioners (#473)
Browse files Browse the repository at this point in the history
  • Loading branch information
alexmasi authored Dec 14, 2023
1 parent 47b283f commit 4ba4cda
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 0 deletions.
13 changes: 13 additions & 0 deletions cloudbuild/external.pkr.hcl
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,9 @@ build {
"sudo apt-get -o DPkg::Lock::Timeout=60 update",
"sudo apt-get -o DPkg::Lock::Timeout=60 install kubelet kubeadm kubectl -y",
"kubectl version --client",
"echo 'source <(kubectl completion bash)' >> ~/.bashrc",
"echo 'alias k=kubectl' >> ~/.bashrc",
"echo 'complete -o default -F __start_kubectl k' >> ~/.bashrc",
]
}

Expand Down Expand Up @@ -153,4 +156,14 @@ build {
"/home/$USER/go/bin/go-licenses save github.com/openconfig/ondatra --save_path=\"../third_party/licenses/ondatra\"",
]
}

provisioner "shell" {
inline = [
"echo Installing openconfig tools...",
"sudo apt-get -o DPkg::Lock::Timeout=60 install tree -y",
"bash -c \"$(curl -sL https://get-gnmic.openconfig.net)\"",
"bash -c \"$(curl -sL https://get-gribic.kmrd.dev)\"",
"bash -c \"$(curl -sL https://get-gnoic.kmrd.dev)\"",
]
}
}
13 changes: 13 additions & 0 deletions cloudbuild/internal.pkr.hcl
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,9 @@ build {
"sudo apt-get -o DPkg::Lock::Timeout=60 update",
"sudo apt-get -o DPkg::Lock::Timeout=60 install kubelet kubeadm kubectl -y",
"kubectl version --client",
"echo 'source <(kubectl completion bash)' >> ~/.bashrc",
"echo 'alias k=kubectl' >> ~/.bashrc",
"echo 'complete -o default -F __start_kubectl k' >> ~/.bashrc",
]
}

Expand Down Expand Up @@ -158,6 +161,16 @@ build {
]
}

provisioner "shell" {
inline = [
"echo Installing openconfig tools...",
"sudo apt-get -o DPkg::Lock::Timeout=60 install tree -y",
"bash -c \"$(curl -sL https://get-gnmic.openconfig.net)\"",
"bash -c \"$(curl -sL https://get-gribic.kmrd.dev)\"",
"bash -c \"$(curl -sL https://get-gnoic.kmrd.dev)\"",
]
}

provisioner "shell" {
inline = [
"echo Installing Google cloud ops agent...",
Expand Down

0 comments on commit 4ba4cda

Please sign in to comment.