Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add plugins.removeList to allow remove plugins #526

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
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
3 changes: 3 additions & 0 deletions charts/opensearch-dashboards/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -169,6 +169,9 @@ spec:
- |
#!/usr/bin/bash
set -e
{{- range $plugin := .Values.plugins.removeList }}
./bin/opensearch-dashboards-plugin remove {{ $plugin }}
{{- end }}
{{- range $plugin := .Values.plugins.installList }}
./bin/opensearch-dashboards-plugin install {{ $plugin }}
{{- end }}
Expand Down
2 changes: 2 additions & 0 deletions charts/opensearch-dashboards/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -274,3 +274,5 @@ plugins:
enabled: false
installList: []
# - example-fake-plugin-downloadable-url
removeList: []
# - securityDashboards
6 changes: 6 additions & 0 deletions charts/opensearch/templates/statefulset.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -360,6 +360,12 @@ spec:
#!/usr/bin/env bash
set -euo pipefail

{{- range $plugin := .Values.plugins.removeList }}
if ./bin/opensearch-plugin list | grep -q {{ $plugin }}; then
./bin/opensearch-plugin remove {{ $plugin }}
fi
{{- end }}

{{- range $plugin := .Values.plugins.installList }}
./bin/opensearch-plugin install -b {{ $plugin }}
{{- end }}
Expand Down
2 changes: 2 additions & 0 deletions charts/opensearch/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -489,6 +489,8 @@ plugins:
enabled: false
installList: []
# - example-fake-plugin
removeList: []
# - opensearch-ml

# -- Array of extra K8s manifests to deploy
extraObjects: []
Expand Down
Loading