Skip to content

Conversation

sea-gull-diana
Copy link

Hello,

I would like to suggest a small change in the algorithm of plugin installation. Currently, if plugins.install value is not an empty array, all plugins added via marketplace and not mentioned in values are wiped out on pod restart, despite having persistence enabled in values. It poses an issue in cases where a user has to use helm values for some base plugins, but wants to enable those who work with Sonarqube later to install additional plugins from marketplace as needed.

Proposed solution:

I have modified install-plugin.sh script, so that it would write the names of plugin jars installed via values in installed-plugins.txt file and delete only these jars on restart (thus not deleting the plugins installed in another way).

This is NOT a breaking change. If the installed-plugins.txt is not found, the script reverts to original behavior and deletes all plugin files before creating a new txt file and downloading plugins requested in values.

Additionally, I modified the chart to execute the install-plugin.sh script not only if plugins.install array is not empty, but also if persistence is enabled. It seems necessary since with enabled persistence even if currently there are no plugins to install in values, there can be plugin jars remaining from the previous deployment in the persistent volume which need to be removed.

I hope you will take my suggestion into consideration. It would be a helpful feature for users like me. Thank you for your time.

Please ensure your pull request adheres to the following guidelines:

  • explain your motives to contribute this change: what problem you are trying to fix, what improvement you are trying to make
  • Document your Changes in the CHANGELOG.md file of the respected chart as well as the Chart.yaml

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants