From 716cc171971bb6604ada63a613e8a954b9b19caf Mon Sep 17 00:00:00 2001 From: Jason Montleon Date: Tue, 23 Jul 2024 15:13:54 -0400 Subject: [PATCH] :sparkles: Add ALM Examples for new CRs Signed-off-by: Jason Montleon --- ...nveyor-operator.clusterserviceversion.yaml | 87 ++++++++++++++++++- .../tackle.konveyor.io_addons.sample.yaml | 20 +++++ .../tackle.konveyor.io_extensions.sample.yaml | 31 +++++++ .../crds/tackle.konveyor.io_tasks.sample.yaml | 11 +++ 4 files changed, 147 insertions(+), 2 deletions(-) create mode 100644 helm/templates/crds/tackle.konveyor.io_addons.sample.yaml create mode 100644 helm/templates/crds/tackle.konveyor.io_extensions.sample.yaml create mode 100644 helm/templates/crds/tackle.konveyor.io_tasks.sample.yaml diff --git a/bundle/manifests/konveyor-operator.clusterserviceversion.yaml b/bundle/manifests/konveyor-operator.clusterserviceversion.yaml index a2b94b5..b2fa2ba 100644 --- a/bundle/manifests/konveyor-operator.clusterserviceversion.yaml +++ b/bundle/manifests/konveyor-operator.clusterserviceversion.yaml @@ -5,7 +5,76 @@ metadata: alm-examples: |- [ { - "apiVersion": "tackle.konveyor.io/v1alpha2", + "apiVersion": "tackle.konveyor.io/v1alpha1", + "kind": "Addon", + "metadata": { + "name": "myaddon", + "namespace": "konveyor-tackle" + }, + "spec": { + "container": { + "image": "quay.io/konveyor/tackle2-addon-analyzer:latest", + "imagePullPolicy": "Always", + "name": "myaddon", + "resources": { + "limits": { + "cpu": 1, + "memory": "1Gi" + }, + "requests": { + "cpu": 1, + "memory": "512Mi" + } + } + }, + "task": "mytask" + } + }, + { + "apiVersion": "tackle.konveyor.io/v1alpha1", + "kind": "Extension", + "metadata": { + "name": "myextension", + "namespace": "konveyor-tackle" + }, + "spec": { + "addon": "myaddon", + "container": { + "args": [ + "--port", + "$(PORT)" + ], + "env": [ + { + "name": "PORT", + "value": "${seq:8000}" + } + ], + "image": "quay.io/konveyor/generic-external-provider:latest", + "imagePullPolicy": "Always", + "name": "myextension", + "resources": { + "limits": { + "cpu": 1, + "memory": "1Gi" + }, + "requests": { + "cpu": 1, + "memory": "1Gi" + } + } + }, + "metadata": { + "provider": { + "address": "localhost:$(PORT)", + "name": "myextension" + } + }, + "selector": "tag:Language=MyLang" + } + }, + { + "apiVersion": "tackle.konveyor.io/v1alpha1", "kind": "Tackle", "metadata": { "name": "tackle", @@ -14,13 +83,27 @@ metadata: "spec": { "feature_auth_required": "false" } + }, + { + "apiVersion": "tackle.konveyor.io/v1alpha1", + "kind": "Task", + "metadata": { + "name": "mytask", + "namespace": "konveyor-tackle" + }, + "spec": { + "dependencies": [ + "myaddon" + ], + "priority": 10 + } } ] capabilities: Seamless Upgrades categories: Modernization & Migration certified: "false" containerImage: quay.io/konveyor/tackle2-operator:latest - createdAt: "2024-07-16T17:45:16Z" + createdAt: "2024-07-23T19:13:03Z" description: Konveyor is an open-source application modernization platform that helps organizations safely and predictably modernize applications to Kubernetes at scale. diff --git a/helm/templates/crds/tackle.konveyor.io_addons.sample.yaml b/helm/templates/crds/tackle.konveyor.io_addons.sample.yaml new file mode 100644 index 0000000..7179cb0 --- /dev/null +++ b/helm/templates/crds/tackle.konveyor.io_addons.sample.yaml @@ -0,0 +1,20 @@ +{{ if .Values.olm }} +apiVersion: tackle.konveyor.io/v1alpha1 +kind: Addon +metadata: + name: myaddon + namespace: konveyor-tackle +spec: + container: + image: quay.io/konveyor/tackle2-addon-analyzer:latest + imagePullPolicy: Always + name: myaddon + resources: + limits: + cpu: 1 + memory: 1Gi + requests: + cpu: 1 + memory: 512Mi + task: mytask +{{ end }} diff --git a/helm/templates/crds/tackle.konveyor.io_extensions.sample.yaml b/helm/templates/crds/tackle.konveyor.io_extensions.sample.yaml new file mode 100644 index 0000000..3f31896 --- /dev/null +++ b/helm/templates/crds/tackle.konveyor.io_extensions.sample.yaml @@ -0,0 +1,31 @@ +{{ if .Values.olm }} +apiVersion: tackle.konveyor.io/v1alpha1 +kind: Extension +metadata: + name: myextension + namespace: konveyor-tackle +spec: + addon: myaddon + container: + args: + - --port + - $(PORT) + env: + - name: PORT + value: ${seq:8000} + image: quay.io/konveyor/generic-external-provider:latest + imagePullPolicy: Always + name: myextension + resources: + limits: + cpu: 1 + memory: 1Gi + requests: + cpu: 1 + memory: 1Gi + metadata: + provider: + address: localhost:$(PORT) + name: myextension + selector: tag:Language=MyLang +{{ end }} diff --git a/helm/templates/crds/tackle.konveyor.io_tasks.sample.yaml b/helm/templates/crds/tackle.konveyor.io_tasks.sample.yaml new file mode 100644 index 0000000..d42c8bd --- /dev/null +++ b/helm/templates/crds/tackle.konveyor.io_tasks.sample.yaml @@ -0,0 +1,11 @@ +{{ if .Values.olm }} +apiVersion: tackle.konveyor.io/v1alpha1 +kind: Task +metadata: + name: mytask + namespace: konveyor-tackle +spec: + dependencies: + - myaddon + priority: 10 +{{ end }}