From 745d3f4bdd3f3b018b402ff4aeedf9b378dbf2f8 Mon Sep 17 00:00:00 2001 From: Marek Date: Thu, 16 Feb 2023 21:42:15 +0100 Subject: [PATCH] #37 Readme, preparations for release --- README.md | 30 +++++++++++++++++++ .../eck-custom-resources-operator/Chart.yaml | 4 +-- .../eck-custom-resources-operator/README.md | 2 +- .../eck-custom-resources-operator/values.yaml | 4 +-- ...es.eck_v1alpha1_elasticsearchinstance.yaml | 2 +- .../es.eck_v1alpha1_elasticsearchrole.yaml | 2 +- .../es.eck_v1alpha1_elasticsearchuser.yaml | 2 +- .../samples/es.eck_v1alpha1_index-base.yaml | 2 +- config/samples/es.eck_v1alpha1_index.yaml | 2 +- .../es.eck_v1alpha1_indexlifecyclepolicy.yaml | 2 +- .../es.eck_v1alpha1_ingestpipeline.yaml | 2 +- ....eck_v1alpha1_snapshotlifecyclepolicy.yaml | 2 +- .../es.eck_v1alpha1_snapshotrepository.yaml | 2 +- .../kibana.eck_v1alpha1_dashboard.yaml | 2 +- .../samples/kibana.eck_v1alpha1_dataview.yaml | 2 +- .../kibana.eck_v1alpha1_indexpattern.yaml | 2 +- .../kibana.eck_v1alpha1_kibanainstance.yaml | 2 +- config/samples/kibana.eck_v1alpha1_lens.yaml | 2 +- .../kibana.eck_v1alpha1_savedsearch.yaml | 2 +- config/samples/kibana.eck_v1alpha1_space.yaml | 2 +- .../kibana.eck_v1alpha1_visualization.yaml | 2 +- 21 files changed, 52 insertions(+), 22 deletions(-) diff --git a/README.md b/README.md index 21bd185..81ace83 100644 --- a/README.md +++ b/README.md @@ -37,6 +37,36 @@ Configuration options are documented in [chart README file](charts/eck-custom-re ## Upgrade guide +### From 0.4.1 to 0.5.0 +The Multi-target support was introduced. This changes is backward compatible, but in order to make use of the multi-target support +apply the new CRDs manually: +``` + +kubectl apply --server-side -f https://raw.githubusercontent.com/xco-sk/eck-custom-resources/eck-custom-resources-operator-0.5.0/config/crd/bases/es.eck.github.com_elasticsearchinstances.yaml +kubectl apply --server-side -f https://raw.githubusercontent.com/xco-sk/eck-custom-resources/eck-custom-resources-operator-0.5.0/config/crd/bases/es.eck.github.com_elasticsearchroles.yaml +kubectl apply --server-side -f https://raw.githubusercontent.com/xco-sk/eck-custom-resources/eck-custom-resources-operator-0.5.0/config/crd/bases/es.eck.github.com_elasticsearchusers.yaml +kubectl apply --server-side -f https://raw.githubusercontent.com/xco-sk/eck-custom-resources/eck-custom-resources-operator-0.5.0/config/crd/bases/es.eck.github.com_indexlifecyclepolicies.yaml +kubectl apply --server-side -f https://raw.githubusercontent.com/xco-sk/eck-custom-resources/eck-custom-resources-operator-0.5.0/config/crd/bases/es.eck.github.com_indextemplates.yaml +kubectl apply --server-side -f https://raw.githubusercontent.com/xco-sk/eck-custom-resources/eck-custom-resources-operator-0.5.0/config/crd/bases/es.eck.github.com_indices.yaml +kubectl apply --server-side -f https://raw.githubusercontent.com/xco-sk/eck-custom-resources/eck-custom-resources-operator-0.5.0/config/crd/bases/es.eck.github.com_ingestpipelines.yaml +kubectl apply --server-side -f https://raw.githubusercontent.com/xco-sk/eck-custom-resources/eck-custom-resources-operator-0.5.0/config/crd/bases/es.eck.github.com_snapshotlifecyclepolicies.yaml +kubectl apply --server-side -f https://raw.githubusercontent.com/xco-sk/eck-custom-resources/eck-custom-resources-operator-0.5.0/config/crd/bases/es.eck.github.com_snapshotrepositories.yaml +kubectl apply --server-side -f https://raw.githubusercontent.com/xco-sk/eck-custom-resources/eck-custom-resources-operator-0.5.0/config/crd/bases/kibana.eck.github.com_kibanainstances.yaml +kubectl apply --server-side -f https://raw.githubusercontent.com/xco-sk/eck-custom-resources/eck-custom-resources-operator-0.5.0/config/crd/bases/kibana.eck.github.com_dashboards.yaml +kubectl apply --server-side -f https://raw.githubusercontent.com/xco-sk/eck-custom-resources/eck-custom-resources-operator-0.5.0/config/crd/bases/kibana.eck.github.com_indexpatterns.yaml +kubectl apply --server-side -f https://raw.githubusercontent.com/xco-sk/eck-custom-resources/eck-custom-resources-operator-0.5.0/config/crd/bases/kibana.eck.github.com_lens.yaml +kubectl apply --server-side -f https://raw.githubusercontent.com/xco-sk/eck-custom-resources/eck-custom-resources-operator-0.5.0/config/crd/bases/kibana.eck.github.com_savedsearches.yaml +kubectl apply --server-side -f https://raw.githubusercontent.com/xco-sk/eck-custom-resources/eck-custom-resources-operator-0.5.0/config/crd/bases/kibana.eck.github.com_spaces.yaml +kubectl apply --server-side -f https://raw.githubusercontent.com/xco-sk/eck-custom-resources/eck-custom-resources-operator-0.5.0/config/crd/bases/kibana.eck.github.com_visualizations.yaml +``` + +There are 2 new CRDs, `ElasticsearchInstance` and `KibanaInstance` that allows you to deploy the target configuration for +both Kibana and Elasticsearch. The rest of the CRDs were extended with optional `targetInstance.name` field, that should reference +the `ElasticsearchInstance`/`KibanaInstance`. If `targetInstance` field is not present, the default operator configuration (`elasticsearch` and `kibana` +fields) is used. These two fields of operator configuration can stay empty if you want to ake use of fail-fast principle. +This approach should ensure the backward compatibility with previously deployed CRDs. +See [samples](config/samples). + ### From 0.3.2 to 0.4.1 There is new `DataView` CRD present. To apply the CRD, run: ``` diff --git a/charts/eck-custom-resources-operator/Chart.yaml b/charts/eck-custom-resources-operator/Chart.yaml index 2c4942b..56618ac 100644 --- a/charts/eck-custom-resources-operator/Chart.yaml +++ b/charts/eck-custom-resources-operator/Chart.yaml @@ -9,5 +9,5 @@ maintainers: email: marek@xco.sk url: https://github.com/xco-sk type: application -version: 0.4.4 -appVersion: 0.4.1 +version: 0.5.0 +appVersion: 0.5.0 diff --git a/charts/eck-custom-resources-operator/README.md b/charts/eck-custom-resources-operator/README.md index 176529a..ff88e2a 100644 --- a/charts/eck-custom-resources-operator/README.md +++ b/charts/eck-custom-resources-operator/README.md @@ -1,6 +1,6 @@ # Helm chart for eck-custom-resources -![Version: 0.4.4](https://img.shields.io/badge/Version-0.4.4-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 0.4.1](https://img.shields.io/badge/AppVersion-0.4.1-informational?style=flat-square) +![Version: 0.5.0](https://img.shields.io/badge/Version-0.5.0-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 0.5.0](https://img.shields.io/badge/AppVersion-0.5.0-informational?style=flat-square) Helm chart for eck-custom-resources operator diff --git a/charts/eck-custom-resources-operator/values.yaml b/charts/eck-custom-resources-operator/values.yaml index 7c41c57..97ccfe7 100644 --- a/charts/eck-custom-resources-operator/values.yaml +++ b/charts/eck-custom-resources-operator/values.yaml @@ -111,7 +111,7 @@ metrics: # -- Metrics service port port: 8080 -# Configuration of Elasticsearch cluster to which the Custom resources are deployed +# Configuration of Default Elasticsearch cluster to which the Custom resources are deployed. Can stay empty if you want to only use the ElasticsearchInstance CRD approach elasticsearch: # -- Flag to define if the Elasticsearch reconciler is enabled or not enabled: true @@ -130,7 +130,7 @@ elasticsearch: # -- Username of user that is used to manage deployed resources userName: elastic -# Configuration of Kibana to which the Custom resources are deployed +# Configuration of Default Kibana to which the Custom resources are deployed. Can stay empty if you want to only use the KibanaInstance CRD approach kibana: # -- Flag to define if the Kibana reconciler is enabled or not enabled: true diff --git a/config/samples/es.eck_v1alpha1_elasticsearchinstance.yaml b/config/samples/es.eck_v1alpha1_elasticsearchinstance.yaml index a560377..67d611d 100644 --- a/config/samples/es.eck_v1alpha1_elasticsearchinstance.yaml +++ b/config/samples/es.eck_v1alpha1_elasticsearchinstance.yaml @@ -1,7 +1,7 @@ apiVersion: es.eck.github.com/v1alpha1 kind: ElasticsearchInstance metadata: - name: elasticsearch-sample + name: elasticsearch-quickstart spec: enabled: true url: https://quickstart-es-http:9200 diff --git a/config/samples/es.eck_v1alpha1_elasticsearchrole.yaml b/config/samples/es.eck_v1alpha1_elasticsearchrole.yaml index 1dc679c..1e901d8 100644 --- a/config/samples/es.eck_v1alpha1_elasticsearchrole.yaml +++ b/config/samples/es.eck_v1alpha1_elasticsearchrole.yaml @@ -4,7 +4,7 @@ metadata: name: elasticsearchrole-sample spec: targetInstance: - name: elasticsearch-sample + name: elasticsearch-quickstart body: | { "cluster": ["all"], diff --git a/config/samples/es.eck_v1alpha1_elasticsearchuser.yaml b/config/samples/es.eck_v1alpha1_elasticsearchuser.yaml index 4214413..a31c060 100644 --- a/config/samples/es.eck_v1alpha1_elasticsearchuser.yaml +++ b/config/samples/es.eck_v1alpha1_elasticsearchuser.yaml @@ -13,7 +13,7 @@ metadata: name: elasticsearchuser-sample spec: targetInstance: - name: elasticsearch-sample + name: elasticsearch-quickstart secretName: elasticsearchuser-secret body: | { diff --git a/config/samples/es.eck_v1alpha1_index-base.yaml b/config/samples/es.eck_v1alpha1_index-base.yaml index 70df885..0d0443c 100644 --- a/config/samples/es.eck_v1alpha1_index-base.yaml +++ b/config/samples/es.eck_v1alpha1_index-base.yaml @@ -4,7 +4,7 @@ metadata: name: index-base-sample spec: targetInstance: - name: elasticsearch-sample + name: elasticsearch-quickstart dependencies: indexTemplates: - indextemplate-sample diff --git a/config/samples/es.eck_v1alpha1_index.yaml b/config/samples/es.eck_v1alpha1_index.yaml index 386edc0..050eaf1 100644 --- a/config/samples/es.eck_v1alpha1_index.yaml +++ b/config/samples/es.eck_v1alpha1_index.yaml @@ -4,7 +4,7 @@ metadata: name: index-sample spec: targetInstance: - name: elasticsearch-sample + name: elasticsearch-quickstart dependencies: indexTemplates: - indextemplate-sample diff --git a/config/samples/es.eck_v1alpha1_indexlifecyclepolicy.yaml b/config/samples/es.eck_v1alpha1_indexlifecyclepolicy.yaml index c0f2f13..be452a3 100644 --- a/config/samples/es.eck_v1alpha1_indexlifecyclepolicy.yaml +++ b/config/samples/es.eck_v1alpha1_indexlifecyclepolicy.yaml @@ -4,7 +4,7 @@ metadata: name: indexlifecyclepolicy-sample spec: targetInstance: - name: elasticsearch-sample + name: elasticsearch-quickstart body: | { "policy": { diff --git a/config/samples/es.eck_v1alpha1_ingestpipeline.yaml b/config/samples/es.eck_v1alpha1_ingestpipeline.yaml index bfcd439..0d9dced 100644 --- a/config/samples/es.eck_v1alpha1_ingestpipeline.yaml +++ b/config/samples/es.eck_v1alpha1_ingestpipeline.yaml @@ -4,7 +4,7 @@ metadata: name: ingestpipeline-sample spec: targetInstance: - name: elasticsearch-sample + name: elasticsearch-quickstart body: | { "description" : "Ingest pipeline sample", diff --git a/config/samples/es.eck_v1alpha1_snapshotlifecyclepolicy.yaml b/config/samples/es.eck_v1alpha1_snapshotlifecyclepolicy.yaml index 2c221a8..3d531b7 100644 --- a/config/samples/es.eck_v1alpha1_snapshotlifecyclepolicy.yaml +++ b/config/samples/es.eck_v1alpha1_snapshotlifecyclepolicy.yaml @@ -4,7 +4,7 @@ metadata: name: snapshotlifecyclepolicy-sample spec: targetInstance: - name: elasticsearch-sample + name: elasticsearch-quickstart body: | { "schedule": "0 30 1 * * ?", diff --git a/config/samples/es.eck_v1alpha1_snapshotrepository.yaml b/config/samples/es.eck_v1alpha1_snapshotrepository.yaml index 2d97fa1..1fa7dff 100644 --- a/config/samples/es.eck_v1alpha1_snapshotrepository.yaml +++ b/config/samples/es.eck_v1alpha1_snapshotrepository.yaml @@ -4,7 +4,7 @@ metadata: name: snapshotrepository-sample spec: targetInstance: - name: elasticsearch-sample + name: elasticsearch-quickstart body: | { "type": "fs", diff --git a/config/samples/kibana.eck_v1alpha1_dashboard.yaml b/config/samples/kibana.eck_v1alpha1_dashboard.yaml index c747b41..4bb434c 100644 --- a/config/samples/kibana.eck_v1alpha1_dashboard.yaml +++ b/config/samples/kibana.eck_v1alpha1_dashboard.yaml @@ -4,7 +4,7 @@ metadata: name: dashboard-sample spec: targetInstance: - name: kibana-sample + name: kibana-quickstart space: my-space dependencies: - type: lens diff --git a/config/samples/kibana.eck_v1alpha1_dataview.yaml b/config/samples/kibana.eck_v1alpha1_dataview.yaml index b6f647e..eabe614 100644 --- a/config/samples/kibana.eck_v1alpha1_dataview.yaml +++ b/config/samples/kibana.eck_v1alpha1_dataview.yaml @@ -4,7 +4,7 @@ metadata: name: dataview-sample spec: targetInstance: - name: kibana-sample + name: kibana-quickstart space: space-sample dependencies: - type: lens diff --git a/config/samples/kibana.eck_v1alpha1_indexpattern.yaml b/config/samples/kibana.eck_v1alpha1_indexpattern.yaml index a78fe2f..e002374 100644 --- a/config/samples/kibana.eck_v1alpha1_indexpattern.yaml +++ b/config/samples/kibana.eck_v1alpha1_indexpattern.yaml @@ -4,7 +4,7 @@ metadata: name: indexpattern-sample spec: targetInstance: - name: kibana-sample + name: kibana-quickstart body: | { "attributes": { diff --git a/config/samples/kibana.eck_v1alpha1_kibanainstance.yaml b/config/samples/kibana.eck_v1alpha1_kibanainstance.yaml index a36a239..202f9a0 100644 --- a/config/samples/kibana.eck_v1alpha1_kibanainstance.yaml +++ b/config/samples/kibana.eck_v1alpha1_kibanainstance.yaml @@ -1,7 +1,7 @@ apiVersion: kibana.eck.github.com/v1alpha1 kind: KibanaInstance metadata: - name: kibana-sample + name: kibana-quickstart spec: enabled: true url: https://quickstart-kb-http:5601 diff --git a/config/samples/kibana.eck_v1alpha1_lens.yaml b/config/samples/kibana.eck_v1alpha1_lens.yaml index acf7e13..63b2dd5 100644 --- a/config/samples/kibana.eck_v1alpha1_lens.yaml +++ b/config/samples/kibana.eck_v1alpha1_lens.yaml @@ -4,7 +4,7 @@ metadata: name: lens-sample spec: targetInstance: - name: kibana-sample + name: kibana-quickstart space: my-space dependencies: - type: index-pattern diff --git a/config/samples/kibana.eck_v1alpha1_savedsearch.yaml b/config/samples/kibana.eck_v1alpha1_savedsearch.yaml index 178d3cc..e614913 100644 --- a/config/samples/kibana.eck_v1alpha1_savedsearch.yaml +++ b/config/samples/kibana.eck_v1alpha1_savedsearch.yaml @@ -4,7 +4,7 @@ metadata: name: savedsearch-sample spec: targetInstance: - name: kibana-sample + name: kibana-quickstart dependencies: - type: index-pattern name: indexpattern-sample diff --git a/config/samples/kibana.eck_v1alpha1_space.yaml b/config/samples/kibana.eck_v1alpha1_space.yaml index 1821a30..2ea170b 100644 --- a/config/samples/kibana.eck_v1alpha1_space.yaml +++ b/config/samples/kibana.eck_v1alpha1_space.yaml @@ -4,7 +4,7 @@ metadata: name: space-sample spec: targetInstance: - name: kibana-sample + name: kibana-quickstart body: | { "name": "ECK Space sample", diff --git a/config/samples/kibana.eck_v1alpha1_visualization.yaml b/config/samples/kibana.eck_v1alpha1_visualization.yaml index fad688b..6d74b73 100644 --- a/config/samples/kibana.eck_v1alpha1_visualization.yaml +++ b/config/samples/kibana.eck_v1alpha1_visualization.yaml @@ -4,7 +4,7 @@ metadata: name: visualization-sample spec: targetInstance: - name: kibana-sample + name: kibana-quickstart dependencies: - type: index-pattern name: indexpattern-sample