You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I tried the steps above on the M1, but it failed with the new versions of Go. What I ended up doing was building it in a container instead, with an older version of Origin (3.6) and an older version of Go (1.9). Later versions of Origin threw a gssapi missing error, while on version 3.6, it recognised Go >= 1.10 as being lower than 1.7, which was the minimum requirement.
Here's what I had to do:
cd $GOPATH
mkdir -p src/github.com/openshift
git clone -b release-3.6 https://github.com/openshift/origin.git src/github.com/openshift/origin
cd src/github.com/openshift/origin
docker run --rm -v $PWD:/go/src/github.com/openshift/origin -w /go/src/github.com/openshift/origin -it golang:1.9 make build WHAT=cmd/oc
docker run --rm -v $PWD/_output/local/bin/linux/arm64/oc:/usr/local/bin/oc -it golang:1.9 oc version
That obviously means you cannot run it on Mac directly but will always have to go through docker, but that's a compromise I'm fine with. The other way would have been to compile Go 1.9 on the Mac and then build oc from there, which I didn't have time to figure out how to do.
Building on Apple M1
I tried the steps above on the M1, but it failed with the new versions of Go. What I ended up doing was building it in a container instead, with an older version of Origin (3.6) and an older version of Go (1.9). Later versions of Origin threw a
gssapi missing
error, while on version 3.6, it recognised Go >= 1.10 as being lower than 1.7, which was the minimum requirement.Here's what I had to do:
That obviously means you cannot run it on Mac directly but will always have to go through docker, but that's a compromise I'm fine with. The other way would have been to compile Go 1.9 on the Mac and then build oc from there, which I didn't have time to figure out how to do.