argo-cd/hack/update-openapi.sh
jannfis 23bf07d206
chore: Migrate to Go modules (#3639)
* chore: Migrate to Go modules

* Update CircleCI config

* Fix path

* Attach vendor for test step correctly

* restore_vendor -> attach_vendor

* Update cache path

* Checkout code before attaching vendor

* Move checkout to even earlier in job

* Don't restore cache for e2e step

* .

* Explicitly set GOPATH

* Restore Build cache

* Fix permissions

* Set correct environment for docker env

* Uncache everything

* Fix permissions

* Use workspace for caching Go code

* .

* go mod tidy

* Try to speed up builds

* Make mod target implicit dependencies

* Do not call make mod-download or mod-vendor

* Fix permissions

* Don't have modules dependendencies on test-e2e-local

* Fix confgi

* Bye bye

* Remove test parallelism

* Get max test parallelism back in, but with lower value
2020-05-26 18:15:38 +02:00

21 lines
652 B
Bash
Executable file

#!/bin/bash
set -x
set -o errexit
set -o nounset
set -o pipefail
PROJECT_ROOT=$(cd $(dirname "$0")/.. ; pwd)
CODEGEN_PKG=${PROJECT_ROOT}/vendor/k8s.io/kube-openapi
VERSION="v1alpha1"
go build -o dist/openapi-gen ${CODEGEN_PKG}/cmd/openapi-gen
./dist/openapi-gen \
--go-header-file ${PROJECT_ROOT}/hack/custom-boilerplate.go.txt \
--input-dirs github.com/argoproj/argo-cd/pkg/apis/application/${VERSION} \
--output-package github.com/argoproj/argo-cd/pkg/apis/application/${VERSION} \
--report-filename pkg/apis/api-rules/violation_exceptions.list \
$@
go build -o ./dist/gen-crd-spec ${PROJECT_ROOT}/hack/gen-crd-spec
./dist/gen-crd-spec