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

New setting to explicitly enable plugins #184

Merged
merged 1 commit into from
Jul 3, 2024

Conversation

hoegaarden
Copy link
Contributor

@hoegaarden hoegaarden commented Jun 25, 2024

This introduces a new config value PLUGINS_ENABLED, which is a list of plugins which should be loaded after being discovered successfully.

Use-case:

A container image can be produced, shipping multiple plugins, but still giving users control over which ones get actually loaded.

@hoegaarden hoegaarden force-pushed the hhoerl/ignore_plugins branch from 1c732e3 to 7c390df Compare June 25, 2024 17:48
@kbialek
Copy link
Owner

kbialek commented Jun 30, 2024

hi @hoegaarden, Why opt-out instead of opt-in? Or in other words why PLUGINS_DISABLE and not PLUGINS_ENABLE?

@hoegaarden
Copy link
Contributor Author

Don't have a strong opinion on that.

To me it makes slightly more sense to, by default, load all plugins that happen to reside in the plugins directory, but allow users to selectively disable certain plugins.
FWIW, tho probably not super important: this keeps the current default behavior.

But again, no strong opinion.

@kbialek
Copy link
Owner

kbialek commented Jun 30, 2024

I prefer to focus on and specify what I need instead of what I do not need. Also, imagine what will happen when you release a new version of your image, with some new plugins bundled. They will be automatically activated. I doubt if that is desired.

EDIT:
My suggestion is to implement PLUGINS_ENABLED and break backwards compatibility here. I will highlight it in the release notes then.

This introduces a new config value `PLUGINS_ENABLED`, which is a list of
plugin names. Those, and only those, which are configured in this list
will be loaded after they have been discovered in the plugins directory.

Use-case:

A container image can be produced, shipping multiple plugins, but still
giving users control over which ones get actually loaded.
@hoegaarden hoegaarden force-pushed the hhoerl/ignore_plugins branch from 7c390df to 484a786 Compare June 30, 2024 18:53
@hoegaarden
Copy link
Contributor Author

/ptal @kbialek

@hoegaarden hoegaarden changed the title Allow plugins to be disabled New setting to explicitly enable plugins Jun 30, 2024
@kbialek kbialek merged commit eb1fa55 into kbialek:main Jul 3, 2024
1 check passed
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