Merge pull request #87 from piotrmsc/fix/ci
fix: installing kubebuilder binary.
This commit is contained in:
commit
123d62e650
@ -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
|
version: 2
|
||||||
jobs:
|
jobs:
|
||||||
build:
|
build:
|
||||||
@ -7,19 +23,7 @@ jobs:
|
|||||||
steps:
|
steps:
|
||||||
- checkout
|
- checkout
|
||||||
- run:
|
- run:
|
||||||
name: Fetch kube-builder
|
<<: *install-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
|
|
||||||
|
|
||||||
- run: make
|
- run: make
|
||||||
test:
|
test:
|
||||||
docker:
|
docker:
|
||||||
@ -28,18 +32,7 @@ jobs:
|
|||||||
steps:
|
steps:
|
||||||
- checkout
|
- checkout
|
||||||
- run:
|
- run:
|
||||||
name: Fetch kube-builder
|
<<: *install-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
|
|
||||||
- run: make test
|
- run: make test
|
||||||
test-integration:
|
test-integration:
|
||||||
machine: true
|
machine: true
|
||||||
@ -54,18 +47,7 @@ jobs:
|
|||||||
sudo echo "export PATH=$PATH:/usr/local/go/bin" >> $HOME/.profile
|
sudo echo "export PATH=$PATH:/usr/local/go/bin" >> $HOME/.profile
|
||||||
go version
|
go version
|
||||||
- run:
|
- run:
|
||||||
name: Download kube-builder
|
<<: *install-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
|
|
||||||
- run:
|
- run:
|
||||||
name: Install kustomize
|
name: Install kustomize
|
||||||
command: |
|
command: |
|
||||||
|
Loading…
x
Reference in New Issue
Block a user