fix: installing kubebuilder binary.
Added anchor for installing kube builder and using links in the steps for it.
This commit is contained in:
parent
c97df27d0f
commit
36879b4803
@ -1,3 +1,19 @@
|
||||
kube-builder: &install-kube-builder
|
||||
name: Fetch kube-builder
|
||||
command: |
|
||||
os=$(go env GOOS)
|
||||
arch=$(go env GOARCH)
|
||||
|
||||
# Download kubebuilder and extract it to tmp
|
||||
# Temporary solution, older versions of kubebuilder are nolonger available under old urls.
|
||||
# Upgrading kubebuilder to latest version is a bigger story and needs more work.
|
||||
# We will use direct GH release URL for now.
|
||||
curl -sL https://github.com/kubernetes-sigs/kubebuilder/releases/download/v2.3.2/kubebuilder_2.3.2_${os}_${arch}.tar.gz | tar -xz -C /tmp/
|
||||
|
||||
# move to a long-term location and put it on your path
|
||||
# (you'll need to set the KUBEBUILDER_ASSETS env var if you put it somewhere else)
|
||||
sudo mv /tmp/kubebuilder_2.3.2_${os}_${arch} /usr/local/kubebuilder
|
||||
export PATH=$PATH:/usr/local/kubebuilder/bin
|
||||
version: 2
|
||||
jobs:
|
||||
build:
|
||||
@ -7,19 +23,7 @@ jobs:
|
||||
steps:
|
||||
- checkout
|
||||
- run:
|
||||
name: Fetch kube-builder
|
||||
command: |
|
||||
os=$(go env GOOS)
|
||||
arch=$(go env GOARCH)
|
||||
|
||||
# download kubebuilder and extract it to tmp
|
||||
curl -sL https://go.kubebuilder.io/dl/2.3.2/${os}/${arch} | tar -xz -C /tmp/
|
||||
|
||||
# move to a long-term location and put it on your path
|
||||
# (you'll need to set the KUBEBUILDER_ASSETS env var if you put it somewhere else)
|
||||
sudo mv /tmp/kubebuilder_2.3.2_${os}_${arch} /usr/local/kubebuilder
|
||||
export PATH=$PATH:/usr/local/kubebuilder/bin
|
||||
|
||||
<<: *install-kube-builder
|
||||
- run: make
|
||||
test:
|
||||
docker:
|
||||
@ -28,18 +32,7 @@ jobs:
|
||||
steps:
|
||||
- checkout
|
||||
- run:
|
||||
name: Fetch kube-builder
|
||||
command: |
|
||||
os=$(go env GOOS)
|
||||
arch=$(go env GOARCH)
|
||||
|
||||
# download kubebuilder and extract it to tmp
|
||||
curl -sL https://go.kubebuilder.io/dl/2.3.2/${os}/${arch} | tar -xz -C /tmp/
|
||||
|
||||
# move to a long-term location and put it on your path
|
||||
# (you'll need to set the KUBEBUILDER_ASSETS env var if you put it somewhere else)
|
||||
sudo mv /tmp/kubebuilder_2.3.2_${os}_${arch} /usr/local/kubebuilder
|
||||
export PATH=$PATH:/usr/local/kubebuilder/bin
|
||||
<<: *install-kube-builder
|
||||
- run: make test
|
||||
test-integration:
|
||||
machine: true
|
||||
@ -54,18 +47,7 @@ jobs:
|
||||
sudo echo "export PATH=$PATH:/usr/local/go/bin" >> $HOME/.profile
|
||||
go version
|
||||
- run:
|
||||
name: Download kube-builder
|
||||
command: |
|
||||
os=$(go env GOOS)
|
||||
arch=$(go env GOARCH)
|
||||
|
||||
# download kubebuilder and extract it to tmp
|
||||
curl -sL https://go.kubebuilder.io/dl/2.3.2/${os}/${arch} | tar -xz -C /tmp/
|
||||
|
||||
# move to a long-term location and put it on your path
|
||||
# (you'll need to set the KUBEBUILDER_ASSETS env var if you put it somewhere else)
|
||||
sudo mv /tmp/kubebuilder_2.3.2_${os}_${arch} /usr/local/kubebuilder
|
||||
sudo echo "export PATH=$PATH:/usr/local/kubebuilder/bin" >> $HOME/.profile
|
||||
<<: *install-kube-builder
|
||||
- run:
|
||||
name: Install kustomize
|
||||
command: |
|
||||
|
Loading…
x
Reference in New Issue
Block a user