Skip to content

Commit

Permalink
Clean removal of MCADv1 and Instascale (#501)
Browse files Browse the repository at this point in the history
* Clean removal of MCAD and Instascale

* entirely remove the MCAD/Instascale config structs

* untested port of odh ray test to non-appwrapper version
  • Loading branch information
dgrove-oss committed Apr 5, 2024
1 parent be7ac07 commit c771aae
Show file tree
Hide file tree
Showing 21 changed files with 39 additions and 1,790 deletions.
18 changes: 0 additions & 18 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -11,16 +11,6 @@ PREVIOUS_VERSION ?= v0.0.0-dev
VERSION ?= v0.0.0-dev
BUNDLE_VERSION ?= $(VERSION:v%=%)

# INSTASCALE_VERSION defines the default version of the InstaScale controller
INSTASCALE_VERSION ?= v0.4.0
INSTASCALE_REPO ?= github.com/project-codeflare/instascale

# MCAD_VERSION defines the default version of the MCAD controller
MCAD_VERSION ?= v1.40.0
MCAD_REPO ?= github.com/project-codeflare/multi-cluster-app-dispatcher
# Upstream MCAD is currently only creating release tags of the form `vX.Y.Z` (i.e the version)
MCAD_CRD ?= ${MCAD_REPO}/config/crd?ref=${MCAD_VERSION}

# KUBERAY_VERSION defines the default version of the KubeRay operator (used for testing)
KUBERAY_VERSION ?= v1.0.0

Expand Down Expand Up @@ -139,9 +129,6 @@ help: ## Display this help.
.PHONY: manifests
manifests: controller-gen kustomize install-yq ## Generate RBAC objects.
$(CONTROLLER_GEN) rbac:roleName=manager-role webhook paths="./..."
$(SED) -i -E "s|(- )\${MCAD_REPO}.*|\1\${MCAD_CRD}|" config/crd/mcad/kustomization.yaml
$(KUSTOMIZE) build config/crd/mcad | $(YQ) -s '"crd-" + .spec.names.singular' --no-doc
mv crd-*.yml config/crd

.PHONY: fmt
fmt: ## Run go fmt against code.
Expand All @@ -156,8 +143,6 @@ vet: ## Run go vet against code.

.PHONY: modules
modules: ## Update Go dependencies.
go get $(MCAD_REPO)@$(MCAD_VERSION)
go get $(INSTASCALE_REPO)@$(INSTASCALE_VERSION)
go get github.com/ray-project/kuberay/ray-operator@$(KUBERAY_VERSION)
go mod tidy

Expand All @@ -166,8 +151,6 @@ build: fmt vet ## Build manager binary.
go build \
-ldflags " \
-X 'main.OperatorVersion=$(BUILD_VERSION)' \
-X 'main.McadVersion=$(MCAD_VERSION)' \
-X 'main.InstaScaleVersion=$(INSTASCALE_VERSION)' \
-X 'main.BuildDate=$(BUILD_DATE)' \
" \
-o bin/manager main.go
Expand Down Expand Up @@ -208,7 +191,6 @@ deploy: manifests kustomize ## Deploy controller to the K8s cluster specified in

.PHONY: undeploy
undeploy: ## Undeploy controller from the K8s cluster specified in ~/.kube/config. Call with ignore-not-found=true to ignore resource not found errors during deletion.
$(SED) -i -E "s|(- )\${MCAD_REPO}.*|\1\${MCAD_CRD}|" config/crd/mcad/kustomization.yaml
$(KUSTOMIZE) build config/${ENV} | kubectl delete --ignore-not-found=$(ignore-not-found) -f -
git restore config/*

Expand Down
462 changes: 0 additions & 462 deletions config/crd/crd-appwrapper.yml

This file was deleted.

115 changes: 0 additions & 115 deletions config/crd/crd-quotasubtree.yml

This file was deleted.

80 changes: 0 additions & 80 deletions config/crd/crd-schedulingspec.yml

This file was deleted.

3 changes: 0 additions & 3 deletions config/crd/kustomization.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,5 @@
# since it depends on service name and namespace that are out of this kustomize package.
# It should be run by config/default
resources:
- crd-appwrapper.yml
- crd-quotasubtree.yml
- crd-schedulingspec.yml

#+kubebuilder:scaffold:crdkustomizeresource
4 changes: 0 additions & 4 deletions config/crd/mcad/kustomization.yaml

This file was deleted.

8 changes: 0 additions & 8 deletions config/e2e/config.yaml

This file was deleted.

1 change: 0 additions & 1 deletion config/e2e/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
namespace: openshift-operators

bases:
- config.yaml
- ../default

patches:
Expand Down
46 changes: 2 additions & 44 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,6 @@ require (
github.com/openshift/api v0.0.0-20230213134911-7ba313770556
github.com/openshift/client-go v0.0.0-20221019143426-16aed247da5c
github.com/project-codeflare/codeflare-common v0.0.0-20240207083912-d7a229270a0a
github.com/project-codeflare/instascale v0.4.0
github.com/project-codeflare/multi-cluster-app-dispatcher v1.40.0
github.com/ray-project/kuberay/ray-operator v1.0.0
go.uber.org/zap v1.26.0
k8s.io/api v0.27.8
Expand All @@ -25,25 +23,16 @@ require (
replace sigs.k8s.io/custom-metrics-apiserver => sigs.k8s.io/custom-metrics-apiserver v1.25.1-0.20230306170449-63d8c93851f3

require (
github.com/NYTimes/gziphandler v1.1.1 // indirect
github.com/antlr/antlr4/runtime/Go/antlr v1.4.10 // indirect
github.com/asaskevich/govalidator v0.0.0-20190424111038-f61b66f89f4a // indirect
github.com/aymerick/douceur v0.2.0 // indirect
github.com/beorn7/perks v1.0.1 // indirect
github.com/blang/semver/v4 v4.0.0 // indirect
github.com/cenkalti/backoff/v4 v4.2.1 // indirect
github.com/cespare/xxhash/v2 v2.2.0 // indirect
github.com/coreos/go-semver v0.3.0 // indirect
github.com/coreos/go-systemd/v22 v22.4.0 // indirect
github.com/davecgh/go-spew v1.1.1 // indirect
github.com/eapache/go-resiliency v1.3.0 // indirect
github.com/emicklei/go-restful/v3 v3.10.1 // indirect
github.com/evanphx/json-patch v4.12.0+incompatible // indirect
github.com/evanphx/json-patch/v5 v5.6.0 // indirect
github.com/felixge/httpsnoop v1.0.3 // indirect
github.com/fsnotify/fsnotify v1.6.0 // indirect
github.com/go-logr/logr v1.2.4 // indirect
github.com/go-logr/stdr v1.2.2 // indirect
github.com/go-logr/zapr v1.2.4 // indirect
github.com/go-openapi/jsonpointer v0.19.6 // indirect
github.com/go-openapi/jsonreference v0.20.1 // indirect
Expand All @@ -54,76 +43,45 @@ require (
github.com/golang/glog v1.1.2 // indirect
github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect
github.com/golang/protobuf v1.5.3 // indirect
github.com/google/cel-go v0.12.7 // indirect
github.com/google/gnostic v0.6.9 // indirect
github.com/google/go-cmp v0.5.9 // indirect
github.com/google/gofuzz v1.2.0 // indirect
github.com/google/pprof v0.0.0-20210720184732-4bb14d4b1be1 // indirect
github.com/google/uuid v1.3.0 // indirect
github.com/gorilla/css v1.0.0 // indirect
github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0 // indirect
github.com/grpc-ecosystem/grpc-gateway/v2 v2.16.0 // indirect
github.com/hashicorp/errwrap v1.0.0 // indirect
github.com/hashicorp/go-multierror v1.1.1 // indirect
github.com/imdario/mergo v0.3.12 // indirect
github.com/inconshreveable/mousetrap v1.1.0 // indirect
github.com/josharian/intern v1.0.0 // indirect
github.com/json-iterator/go v1.1.12 // indirect
github.com/mailru/easyjson v0.7.7 // indirect
github.com/microcosm-cc/bluemonday v1.0.18 // indirect
github.com/mitchellh/mapstructure v1.4.1 // indirect
github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect
github.com/modern-go/reflect2 v1.0.2 // indirect
github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect
github.com/openshift-online/ocm-sdk-go v0.1.368 // indirect
github.com/pkg/errors v0.9.1 // indirect
github.com/project-codeflare/multi-cluster-app-dispatcher v1.37.0 // indirect
github.com/prometheus/client_golang v1.18.0 // indirect
github.com/prometheus/client_model v0.5.0 // indirect
github.com/prometheus/common v0.46.0 // indirect
github.com/prometheus/procfs v0.12.0 // indirect
github.com/spf13/cobra v1.7.0 // indirect
github.com/spf13/pflag v1.0.5 // indirect
github.com/stoewer/go-strcase v1.2.0 // indirect
go.etcd.io/etcd/api/v3 v3.5.7 // indirect
go.etcd.io/etcd/client/pkg/v3 v3.5.7 // indirect
go.etcd.io/etcd/client/v3 v3.5.7 // indirect
go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.45.0 // indirect
go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.45.0 // indirect
go.opentelemetry.io/otel v1.19.0 // indirect
go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.19.0 // indirect
go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.19.0 // indirect
go.opentelemetry.io/otel/metric v1.19.0 // indirect
go.opentelemetry.io/otel/sdk v1.19.0 // indirect
go.opentelemetry.io/otel/trace v1.19.0 // indirect
go.opentelemetry.io/proto/otlp v1.0.0 // indirect
github.com/stretchr/testify v1.8.4 // indirect
go.uber.org/multierr v1.10.0 // indirect
golang.org/x/crypto v0.18.0 // indirect
golang.org/x/net v0.20.0 // indirect
golang.org/x/oauth2 v0.16.0 // indirect
golang.org/x/sync v0.3.0 // indirect
golang.org/x/sys v0.16.0 // indirect
golang.org/x/term v0.16.0 // indirect
golang.org/x/text v0.14.0 // indirect
golang.org/x/time v0.3.0 // indirect
golang.org/x/tools v0.12.0 // indirect
gomodules.xyz/jsonpatch/v2 v2.3.0 // indirect
google.golang.org/appengine v1.6.7 // indirect
google.golang.org/genproto v0.0.0-20230711160842-782d3b101e98 // indirect
google.golang.org/genproto/googleapis/api v0.0.0-20230711160842-782d3b101e98 // indirect
google.golang.org/genproto/googleapis/rpc v0.0.0-20230711160842-782d3b101e98 // indirect
google.golang.org/grpc v1.58.3 // indirect
google.golang.org/protobuf v1.32.0 // indirect
gopkg.in/inf.v0 v0.9.1 // indirect
gopkg.in/natefinch/lumberjack.v2 v2.0.0 // indirect
gopkg.in/yaml.v2 v2.4.0 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
k8s.io/apiextensions-apiserver v0.27.7 // indirect
k8s.io/apiserver v0.27.8 // indirect
k8s.io/kms v0.27.8 // indirect
k8s.io/kube-openapi v0.0.0-20230501164219-8b0f38b5fd1f // indirect
k8s.io/metrics v0.26.2 // indirect
sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.1.2 // indirect
sigs.k8s.io/custom-metrics-apiserver v0.0.0 // indirect
sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd // indirect
sigs.k8s.io/structured-merge-diff/v4 v4.2.3 // indirect
)
Loading

0 comments on commit c771aae

Please sign in to comment.