github.com/openshift/installer@v1.4.17/docs/dev/operators.md (about) 1 # How to add a new operator to the installer? 2 3 This document describes how to provide an operator's configuration files and manifests to installer-launched clusters. 4 5 ## The recommended way 6 7 Most operators should use [the Cluster Version Operator (CVO) payload mechanism][cvo-operators]. 8 9 ## The alternative (for exceptions only) 10 11 Creating a new asset in the installer source is only for exceptional cases where CVO cannot take all the required manifests/config files, and auto-discover is not possible or insufficient e.g. the network operator. As another example, the machine-config-operator needs TLS config. 12 13 Such operators need to be directly integrated in the installer's [`manifests` package](../../pkg/asset/manifests). Within this, there are two ways to get the manifests/config files integrated: 14 15 - A new asset for the operator 16 Create a new operator asset, and render the Dependencies, Name, Load and Generate functions. The Dependencies might contain InstallConfig as an example. In the Generate function, create the config files as asset contents. For the config/manifest’s actual structure, one can choose to vendor the operator’s github pkg, or, if the configuration structures are fairly simple then just copy the definitions directly and avoid the hassle of vendoring. Finally, return the entire list of configs and manifests in the Generate function. 17 18 - Template files 19 In the pkg/asset/manifests/content/openshift directory, place the templates golang variables. Then modify pkg/asset/manifests/openshift.go to expand the template. Expand templateData in template.go for filling up the template variables. 20 21 [cvo-operators]: https://github.com/openshift/enhancements/blob/master/dev-guide/cluster-version-operator/dev/operators.md