Skip to content

Commit

Permalink
REMOVE extension api from main branch
Browse files Browse the repository at this point in the history
  • Loading branch information
acmenezes committed May 7, 2024
1 parent 6d73b73 commit b82812e
Show file tree
Hide file tree
Showing 17 changed files with 49 additions and 1,485 deletions.
5 changes: 2 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@ IMG := $(IMAGE_REPO):$(IMAGE_TAG)
# Define dependency versions (use go.mod if we also use Go code from dependency)
export CERT_MGR_VERSION := v1.9.0
export CATALOGD_VERSION := $(shell go list -mod=mod -m -f "{{.Version}}" github.com/operator-framework/catalogd)
export KAPP_VERSION := $(shell go list -mod=mod -m -f "{{.Version}}" github.com/vmware-tanzu/carvel-kapp-controller)
export RUKPAK_VERSION := $(shell go list -mod=mod -m -f "{{.Version}}" github.com/operator-framework/rukpak)
export WAIT_TIMEOUT := 60s

Expand Down Expand Up @@ -166,7 +165,7 @@ kind-load: $(KIND) #EXHELP Loads the currently constructed image onto the cluste
kind-deploy: export MANIFEST := ./operator-controller.yaml
kind-deploy: manifests $(KUSTOMIZE) #EXHELP Install controller and dependencies onto the kind cluster.
$(KUSTOMIZE) build $(KUSTOMIZE_BUILD_DIR) > operator-controller.yaml
envsubst '$$CATALOGD_VERSION,$$CERT_MGR_VERSION,$$KAPP_VERSION,$$RUKPAK_VERSION,$$MANIFEST' < scripts/install.tpl.sh | bash -s
envsubst '$$CATALOGD_VERSION,$$CERT_MGR_VERSION,$$RUKPAK_VERSION,$$MANIFEST' < scripts/install.tpl.sh | bash -s

.PHONY: kind-cluster
kind-cluster: $(KIND) #EXHELP Standup a kind cluster.
Expand Down Expand Up @@ -254,7 +253,7 @@ release: $(GORELEASER) #EXHELP Runs goreleaser for the operator-controller. By d
quickstart: export MANIFEST := https://github.com/operator-framework/operator-controller/releases/download/$(VERSION)/operator-controller.yaml
quickstart: $(KUSTOMIZE) manifests #EXHELP Generate the installation release manifests and scripts.
$(KUSTOMIZE) build $(KUSTOMIZE_BUILD_DIR) | sed "s/:devel/:$(VERSION)/g" > operator-controller.yaml
envsubst '$$CATALOGD_VERSION,$$CERT_MGR_VERSION,$$KAPP_VERSION,$$RUKPAK_VERSION,$$MANIFEST' < scripts/install.tpl.sh > install.sh
envsubst '$$CATALOGD_VERSION,$$CERT_MGR_VERSION,$$RUKPAK_VERSION,$$MANIFEST' < scripts/install.tpl.sh > install.sh

##@ Docs

Expand Down
18 changes: 18 additions & 0 deletions api/v1alpha1/clusterextension_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,15 @@ import (
type UpgradeConstraintPolicy string

const (

// TypeProgressing indicates whether operator-controller is
// reconciling, installing, updating or deleting an extension.
TypeProgressing = "Progressing"

ReasonProgressing = "Progressing"
ReasonFailedToReachDesiredIntent = "FailedToReachDesiredIntent"
ReasonReachedDesiredIntent = "ReachedDesiredIntent"

// The extension will only upgrade if the new version satisfies
// the upgrade constraints set by the package author.
UpgradeConstraintPolicyEnforce UpgradeConstraintPolicy = "Enforce"
Expand Down Expand Up @@ -106,6 +115,7 @@ func init() {
TypePackageDeprecated,
TypeChannelDeprecated,
TypeBundleDeprecated,
TypeProgressing,
)
// TODO(user): add Reasons from above
conditionsets.ConditionReasons = append(conditionsets.ConditionReasons,
Expand All @@ -118,9 +128,17 @@ func init() {
ReasonInvalidSpec,
ReasonSuccess,
ReasonDeprecated,
ReasonProgressing,
ReasonFailedToReachDesiredIntent,
ReasonReachedDesiredIntent,
)
}

type BundleMetadata struct {
Name string `json:"name"`
Version string `json:"version"`
}

// ClusterExtensionStatus defines the observed state of ClusterExtension
type ClusterExtensionStatus struct {
// +optional
Expand Down
159 changes: 0 additions & 159 deletions api/v1alpha1/extension_types.go

This file was deleted.

142 changes: 0 additions & 142 deletions api/v1alpha1/zz_generated.deepcopy.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 0 additions & 8 deletions cmd/manager/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -108,14 +108,6 @@ func main() {
setupLog.Error(err, "unable to create controller", "controller", "ClusterExtension")
os.Exit(1)
}

if err = (&controllers.ExtensionReconciler{
Client: cl,
BundleProvider: catalogClient,
}).SetupWithManager(mgr); err != nil {
setupLog.Error(err, "unable to create controller", "controller", "Extension")
os.Exit(1)
}
//+kubebuilder:scaffold:builder

if err := mgr.AddHealthzCheck("healthz", healthz.Ping); err != nil {
Expand Down
Loading

0 comments on commit b82812e

Please sign in to comment.