The repository build process is a 2 step process. First build the set of operators you wish to build. Then create the repository index file for that repository.
The "community" repository is the repository for all operators in the community and is a default location for all operator builds. The build process expects the following prerequisites:
kubectl-kudo
andbash
are in the path- your working directory is the root of the checked out
operators
Git repository - you have online web access to the "community" repository during the build process.
./build-operator.sh
is a script within the github repo for building operator packages. It has a number of conveniences based on conventions that have developed. Regardless of convention, a sure way to get a success build using the script is to provide the path to the operator.
./build-operator.sh repository/mysql/operator/
Another option is to provide the name of the operator assuming it is in the "repository/{NAME}/operator" folder as in:
./build-operator.sh mysql
Another convention is to have a version number associated with the build using the convention of "repository/{NAME}/{VERSION}/operator"
./build-operator.sh cassandra 3.11
NOTES:
- Built artifacts will be put under
build/repo
in the current directory. - If you want to add more than 1 operator, build multiple operator packages before building the repository index.
- There is no rebuild and if the operator already exists the build will fail.
To build the repository index simple run ./build-community-repo.sh
or make index
.
This will build an index.yaml
file under build/repo
.
make clean
or ./clean-build.sh
will remove the build/repo
folder.