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

feat(apisix): allow extPlugins to be configured #250

Merged
merged 6 commits into from
Mar 23, 2022
Merged
Show file tree
Hide file tree
Changes from 4 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
8 changes: 8 additions & 0 deletions charts/apisix/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,14 @@ If etcd.enabled is true, set more values of bitnami/etcd helm chart use etcd as

Default enabled plugins. See [configmap template](https://github.com/apache/apisix-helm-chart/blob/master/charts/apisix/templates/configmap.yaml) for details.


### external plugin parameters

| Parameter | Description | Default |
|---------------------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------|-----------------------------|
| `extPlugin.enabled` | Enable External Plugins. See [external plugin](https://apisix.apache.org/docs/apisix/next/external-plugin/) | `false` |
| `extPlugin.cmd` | the command and its arguements to run as a subprocess | `{}` |

### custom plugin parameters

| Parameter | Description | Default |
Expand Down
8 changes: 8 additions & 0 deletions charts/apisix/templates/configmap.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -257,6 +257,14 @@ data:
- {{ $plugin }}
{{- end }}

{{- if .Values.extPlugin.enabled }}
ext-plugin:
cmd:
{{- range $arg := .Values.extPlugin.cmd }}
- {{ $arg }}
{{- end }}
{{- end }}

{{- if or .Values.pluginAttrs .Values.customPlugins.enabled .Values.serviceMonitor.enabled}}
plugin_attr:
{{- if .Values.serviceMonitor.enabled }}
Expand Down
6 changes: 6 additions & 0 deletions charts/apisix/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -210,13 +210,19 @@ plugins:
- traffic-split
- gzip
- real-ip
- ext-plugin-pre-req
- ext-plugin-post-req
stream_plugins:
- mqtt-proxy
- ip-restriction
- limit-conn

pluginAttrs: {}

extPlugin:
enabled: false
cmd: ["/path/to/apisix-plugin-runner/runner", "run"]

# customPlugins allows you to mount your own HTTP plugins.
customPlugins:
enabled: false
Expand Down