Corteza implements the support for Go plugins which can be used to modify default behaviour of the server and provide new functionalities like workflow functions and types.
Enabling and adding plugins to Corteza instance
Plugins can be added to Corteza by specifying their location with
Provide colon separated list of paths to plugin files (plugin file has
Paths can contain wildcards and will be resolved accordingly.
You can quickly disable all plugins by setting
false (enabled by default).
In case plugin is not fully compatible with Corteza, server will refuse to start. It will yield some variation of the following error:
Error: plugin.Open("myplugin"): plugin was built with a different version of package github.com/cortezaproject/corteza-server/pkg/rand
Plugins and Corteza inside Docker container
Plugins need to be accessible to server. You can either map files or directories via volume or copy files inside a new Docker image.
Using container volume parameter
docker run --rm -it \ -v "$(pwd)/myplugin.so:/myplugin.so:ro" \ -e "PLUGINS_PATHS=/myplugin.so" \ "cortezaproject/corteza-server:2021.9"