Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 9 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@ endif

KUSTOMIZE_STANDARD_OVERLAY := config/overlays/standard
KUSTOMIZE_STANDARD_E2E_OVERLAY := config/overlays/standard-e2e
KUSTOMIZE_EXPERIMENTAL_OVERLAY := config/overlays/experimental

export RELEASE_MANIFEST := operator-controller.yaml
export RELEASE_INSTALL := install.sh
Expand All @@ -82,6 +83,7 @@ export RELEASE_CATALOGS := default-catalogs.yaml
MANIFEST_HOME := ./manifests
STANDARD_MANIFEST := ./manifests/standard.yaml
STANDARD_E2E_MANIFEST := ./manifests/standard-e2e.yaml
EXPERIMENTAL_MANIFEST := ./manifests/experimental.yaml
CATALOGS_MANIFEST := ./manifests/default-catalogs.yaml

# Manifest used by kind-deploy, which may be overridden by other targets
Expand Down Expand Up @@ -154,6 +156,7 @@ manifests: $(CONTROLLER_GEN) $(KUSTOMIZE) #EXHELP Generate WebhookConfiguration,
mkdir -p $(MANIFEST_HOME)
$(KUSTOMIZE) build $(KUSTOMIZE_STANDARD_OVERLAY) > $(STANDARD_MANIFEST)
$(KUSTOMIZE) build $(KUSTOMIZE_STANDARD_E2E_OVERLAY) > $(STANDARD_E2E_MANIFEST)
$(KUSTOMIZE) build $(KUSTOMIZE_EXPERIMENTAL_OVERLAY) > $(EXPERIMENTAL_MANIFEST)

.PHONY: generate
generate: $(CONTROLLER_GEN) #EXHELP Generate code containing DeepCopy, DeepCopyInto, and DeepCopyObject method implementations.
Expand Down Expand Up @@ -261,15 +264,15 @@ test-e2e: run image-registry prometheus e2e e2e-metrics e2e-coverage kind-clean
.PHONY: prometheus
prometheus: PROMETHEUS_NAMESPACE := olmv1-system
prometheus: PROMETHEUS_VERSION := v0.83.0
prometheus: #HELP Deploy Prometheus into specified namespace
prometheus: #EXHELP Deploy Prometheus into specified namespace
./hack/test/setup-monitoring.sh $(PROMETHEUS_NAMESPACE) $(PROMETHEUS_VERSION) $(KUSTOMIZE)

# The metrics.out file contains raw json data of the metrics collected during a test run.
# In an upcoming PR, this query will be replaced with one that checks for alerts from
# prometheus. Prometheus will gather metrics we currently query for over the test run,
# and provide alerts from the metrics based on the rules that we set.
.PHONY: e2e-metrics
e2e-metrics: #HELP Request metrics from prometheus; place in ARTIFACT_PATH if set
e2e-metrics: #EXHELP Request metrics from prometheus; place in ARTIFACT_PATH if set
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not related but very small, thank you for the catcher 👍

curl -X POST \
-H "Content-Type: application/x-www-form-urlencoded" \
--data 'query={pod=~"operator-controller-controller-manager-.*|catalogd-controller-manager-.*"}' \
Expand Down Expand Up @@ -384,6 +387,10 @@ go-build-linux: $(BINARIES)
.PHONY: run
run: docker-build kind-cluster kind-load kind-deploy wait #HELP Build the operator-controller then deploy it into a new kind cluster.

.PHONY: run-experimental
run-experimental: SOURCE_MANIFEST := $(EXPERIMENTAL_MANIFEST)
run-experimental: run #HELP Build the operator-controller then deploy it with the experimental manifest into a new kind cluster.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
run-experimental: run #HELP Build the operator-controller then deploy it with the experimental manifest into a new kind cluster.
run-experimental: run #EXHELP Build the operator-controller then deploy it with the experimental manifest into a new kind cluster.


CATD_NAMESPACE := olmv1-system
wait:
kubectl wait --for=condition=Available --namespace=$(CATD_NAMESPACE) deployment/catalogd-controller-manager --timeout=60s
Expand Down
2 changes: 1 addition & 1 deletion config/base/catalogd/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
# Does not include the CRD, which must be added separately (it's non-namespaced)
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
namespace: olmv1-system
namePrefix: catalogd-
resources:
- crd
- rbac
- manager
3 changes: 1 addition & 2 deletions config/base/operator-controller/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
# Does not include the CRD, which must be added separately (it's non-namespaced)
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
namespace: olmv1-system
namePrefix: operator-controller-
resources:
- crd
- rbac
- manager

10 changes: 10 additions & 0 deletions config/components/base/common/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
apiVersion: kustomize.config.k8s.io/v1alpha1
kind: Component
# resources contains the minimal required base, EXCEPT CRDs
resources:
- ../../../base/catalogd
- ../../../base/operator-controller
- ../../../base/common
# components should include any GA'd features (none as of now)
components:

13 changes: 13 additions & 0 deletions config/components/base/experimental/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
apiVersion: kustomize.config.k8s.io/v1alpha1
kind: Component
# Pull in the experimental CRDs
resources:
- ../../../base/catalogd/crd/experimental
- ../../../base/operator-controller/crd/experimental
# Pull in the component(s) common to standard and experimental
components:
- ../common
# EXPERIMENTAL FEATURES ARE LISTED HERE
- ../../features/synthetic-user-permissions
- ../../features/webhook-provider-certmanager
- ../../features/webhook-provider-openshift-serviceca
10 changes: 10 additions & 0 deletions config/components/base/standard/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
apiVersion: kustomize.config.k8s.io/v1alpha1
kind: Component
# Pull in the standard CRDs
resources:
- ../../../base/catalogd/crd/standard
- ../../../base/operator-controller/crd/standard
# Pull in the component(s) common to standard and experimental
components:
- ../common
# GA'D FEATURES ARE LISTED HERE
6 changes: 2 additions & 4 deletions config/overlays/basic-olm/kustomization.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,5 @@
# DO NOT ADD A NAMESPACE HERE
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
resources:
- ../../base/catalogd
- ../../base/operator-controller
- ../../base/common
components:
- ../../components/base/standard
8 changes: 8 additions & 0 deletions config/overlays/experimental/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# kustomization file for secure OLMv1
# DO NOT ADD A NAMESPACE HERE
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
components:
- ../../components/base/experimental
# This must be last due to namespace overwrite issues of the ca
- ../../components/cert-manager
5 changes: 1 addition & 4 deletions config/overlays/standard-e2e/kustomization.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,8 @@
# DO NOT ADD A NAMESPACE HERE
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
resources:
- ../../base/catalogd
- ../../base/operator-controller
- ../../base/common
components:
- ../../components/base/standard
- ../../components/e2e
# This must be last due to namespace overwrite issues of the ca
- ../../components/cert-manager
5 changes: 1 addition & 4 deletions config/overlays/standard/kustomization.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,7 @@
# DO NOT ADD A NAMESPACE HERE
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
resources:
- ../../base/catalogd
- ../../base/operator-controller
- ../../base/common
components:
- ../../components/base/standard
# This must be last due to namespace overwrite issues of the ca
- ../../components/cert-manager
Loading
Loading